BitConverter.DoubleToInt64Bits(Double) Method is used to convert the specified double-precision floating point number to a 64-bit signed integer.
public static long DoubleToInt64Bits (double value);
Here, the value is the number which is to be converted.
Return Value: This method returns a 64-bit signed integer whose value is equivalent to value.
Below programs illustrate the use of BitConverter.DoubleToInt64Bits(Double) Method:
double-precision floating point: 1.23456789012346 64-bit signed integer: 4608238818662570490
double-precision floating point: 1 64-bit signed integer: 4607182418800017408 Hexadecimal value: 3FF0000000000000
Attention reader! Don’t stop learning now. Get hold of all the important DSA concepts with the DSA Self Paced Course at a student-friendly price and become industry ready.