I have following double
value:
8.943
need to convert(cast) into int
e.g: 8.943*1000000 = 8943000
required value --> 8943000
please help!
thanks.
I have following double
value:
8.943
need to convert(cast) into int
e.g: 8.943*1000000 = 8943000
required value --> 8943000
please help!
thanks.
double myDouble = 8.943
int myInt = (int) (myDouble * 1000000)
Using (int) casts the double into an int