Question Bank (3 marks) · Q22
Q.How does the number display 0.013 for a statement printf (“%5.5f”, p) and printf (“%e”, y)
Karnataka PUCTextbookShort· 3mImportance★★★★★est
69% · 107/154 Questions
You're viewing a preview — the full solution, concept, methods & PYQ mapping are locked.
Start your 14-day free trial to unlock the full solution →[!TLDR]
For 0.013, %5.5f prints 0.01300 and %e prints 1.300000e-02.
The value 0.013 is displayed as follows:
(i) printf("%5.5f", p) - .5 forces exactly 5 digits after the decimal point; the field width 5 is only the minimum, so 0.013 is padded on the right with zeros to give five decimals:
0.01300
``` …
Unlock everything free for 14 days
- Full step-by-step solutions
- Concept-first explanations
- Methods, shortcuts & mistakes
- PYQ mapping + timed mock tests
Full access for 14 days. No credit card required.