Hi floks, I have a question concerning floating constants in C.
In Java, the default type of floating point constants in double, so the following will causes a compilation error in java:
float f = 100.0; // we either need to uses type case operator or put f at the end of the number constant.
This is because the default floating-point constants are of type double and casting from double to float without type cast operator is an error, so we need either add a type case operator or put f at the end of the number.
So, Why in C this doesn't produce an error, Is it because the default floating-point constants are of type float, or because the compiler do an implicit down-cast conversion (that doesn't requires type case operator in C)????