variables — what ai reaches for first8 / 9
print, repr, and the f-string
Write three lines.
Line 1: assign 12 to a variable called qty.
Line 2: assign 3.5 to a variable called price.
Line 3: print total: $42.00 using an f-string. The total comes from
qty * price, formatted to two decimal places.
Expected output:
total: $42.00
⌘↵ runs the editor.
Booting Python…
Output
[promptdojo:~]$ _