c# - Add double.MaxValue + double.MaxValue -


I asked this question in an interview, and I was told by the interviewer that there is a legitimate way of getting the output . Need to add two double values:

  double d = double.MaxValue; Double D1 = Double. Maxwell; Var C = D + D1;  

But I get double code . I need to store a large number of outputs.

Perhaps the interviewer should use it for you:

  System Using Numerics; Double d = double. Maxwell; Double D1 = Double. Maxwell; Var c = New BigInteger (D) + New BigInteger (D1); Console.WriteLine (c); // 359538626972463 ...  

Comments