What does "d" in "100d" represent?
Author: wmrgrove
Creation Date: 10/25/2012 2:55 PM
profile picture

wmrgrove

#1
Eugene, a quick, simple ( I hope ) question about the ATR stop code you helped me with? Have searched the documentation and can't find an answer.

In this code line (Rotational Strategy) what is the 100.0d do? I believe it is a divide by 100 but what does the " d " represent and why is there a red "squiggly" under the d ? Thanks! Bill

CODE:
Please log in to see this code.
profile picture

Eugene

#2
d is for double:

C# Suffix
profile picture

Cone

#3
You can either add a decimal or use the "d". It doesn't hurt if you do both, but the editor will whine a little with the red squiggly. Anyway, the idea is to avoid an integer division result.

Notice the results:
CODE:
Please log in to see this code.
profile picture

wmrgrove

#4
Thanks guys, that helps! Bill
This website uses cookies to improve your experience. We'll assume you're ok with that, but you can opt-out if you wish (Read more).