0

C#.net datatype

Why c#.net is not supporting Floating point datatype

16th Aug 2018, 1:46 PM
mupparaju lakshmikumarimupparaju
mupparaju lakshmikumarimupparaju - avatar
1 Réponse
+ 5
It does, by using float & double type: using System; namespace FloatingPointType { class Sample { static void Main(string[] args) { // Single precision floating point float f = 201808.16F; // Double precision floating point double d = 201808.16; Console.WriteLine("float {0}\ndouble {1}", f, d); } } } Or am I misunderstanding your question?
16th Aug 2018, 2:15 PM
Ipang