stackofcodes
Home
Categories
Popular Codes
Articles
/
C
/
Float
Float
I want to print a float value which has 2 integer digits and 6 decimal digits after the comma. If I just use printf("%f", myFloat) I'm getting a truncated value. I don't know if this always happens in C, or it's just because I'm using C for microcontrollers (CCS to be exact), but at the reference it tells that %f get just that: a truncated float. If my float is 44.556677, I'm printing out "44.55", only the first two decimal digits.
0
Share
Similar codes
0 vote
382 views
1 answer
Gitlab ci heroku
C
2 votes
379 views
1 answer
C bitwise integer absolute value
C
0 vote
374 views
1 answer
Sieve of eratosthenes c
C
0 vote
444 views
1 answer
Are two matrcies identical
C
0 vote
326 views
1 answer
Turn on and turn off different device at the same time in rainmaker
C
0 vote
420 views
1 answer
Hello world in c programming languages
C
0 vote
386 views
1 answer
Execute maven project in cmd
C
0 vote
368 views
1 answer
How can i learn c game development
C
0 vote
373 views
1 answer
Python project script run
C
0 vote
386 views
1 answer
How we can strore a nested structure values in arrays
C
Share