Question:

What does the f mean?

by  |  earlier

0 LIKES UnLike

in a piece of c# code I have

double d = 2.02f ;

what does the f mean?

 Tags:

   Report

3 ANSWERS


  1. 'float'. Basically, it's forcing the float value into a double variable.


  2. float.

  3. f means float.

    By default, all decimal numbers (constants) are treated like doubles.

    For example 4.11, 5.4, 3.14 are all doubles because you can give any number of precision digits in a constant. Writing an f next to such a number implicitly means that the constant number is being treated as  a float.

You're reading: What does the f mean?

Question Stats

Latest activity: earlier.
This question has 3 answers.

BECOME A GUIDE

Share your knowledge and help people by answering questions.