PCAP Strings • Set 5
PCAP Strings Practice Test 5 — 15 questions with explanations. Free, no signup.
A team is using f-strings to format a report. They have a variable `value = 0.123456789` and want to display it with exactly 3 significant digits. They write `f"{value:.3g}"`. The output is '0.123'. They expected '0.123'. Is the output correct? If not, what change would produce '0.123'?