Forums Register Login

printf examlab test question 35

+Pie Number of slices to send: Send
Hi,
I have a question on the following code:

The answer is:
7.00settrue.
I thought the answer would be:
07.00settrue
based:
on the flag being 0
and
the width being 2

But I compiled/executed the code and the answer is:
7.00settrue.

I know a there is a thread in the forum discussing the this question, but I can't find it again when I do a search.
So I decided to create a new one.

My question:
what happened to the flag & width ("%02...") portion of the format specifier?

-Thank You
+Pie Number of slices to send: Send
Hi,
Can the admins please delete this post?
I accidently put it in the wrong forum.
I found what I was looking for in the correct forum and I don't need it anymore.
-Thanks
Yeah, but is it art? What do you think tiny ad?
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com


reply
reply
This thread has been viewed 732 times.
Similar Threads
Formatter Doubt
Doubt in formatting
ExamLab Question - Formatting
printf() ??
Formatting
More...

All times above are in ranch (not your local) time.
The current ranch time is
Apr 16, 2024 07:09:31.