I
illegal.prime
Hi all, I have a class that I would like to use to hide the data type
I'm using to store decimal point numbers. Failing all else, I will
just use object and do conversion/casts as necessary. But I was
wondering if I could use double to house all basic/primitive decimal
numbers (i.e. only the float, double and decimal types) in C#. This
type would also have to allow numerical greater than and less than
comparisons.
So I'm pretty sure that it would be safe to use double to house any
float - but what about decimal. Could double be used to house any
decimal?
Thanks,
Novice
I'm using to store decimal point numbers. Failing all else, I will
just use object and do conversion/casts as necessary. But I was
wondering if I could use double to house all basic/primitive decimal
numbers (i.e. only the float, double and decimal types) in C#. This
type would also have to allow numerical greater than and less than
comparisons.
So I'm pretty sure that it would be safe to use double to house any
float - but what about decimal. Could double be used to house any
decimal?
Thanks,
Novice