You didn't really make any mistakes, but your post is lacking information for us to help you.

Do you have an actual question? What specifically didn't work about the double? Did it compile? If...