exercise 60: added hint on correct format

This commit is contained in:
markuxcu
2026-04-03 14:25:44 +02:00
parent 3056a2b544
commit 9f314ce8e6

View File

@@ -49,6 +49,8 @@ pub fn main() void {
// notation. Experiment with '{d}' and '{d:.3}' to see how // notation. Experiment with '{d}' and '{d:.3}' to see how
// decimal formatting works, or try '{e}' and '{e:.3}' for // decimal formatting works, or try '{e}' and '{e:.3}' for
// scientific notation. // scientific notation.
// NOTE: The weight of the shuttle is a huge number, a scientific notation
// may be more appropriate.
print("Shuttle liftoff weight: {d:.0} metric tons\n", .{shuttle_weight / 1e3}); print("Shuttle liftoff weight: {d:.0} metric tons\n", .{shuttle_weight / 1e3});
} }