CHALLENGE 1: A Typed Damage-Calculation Function ==================================================================== TASK ---- Write a typed function calculate_damage(base: int, multiplier: float) -> int that returns the base damage multiplied by the multiplier, rounded down to a whole number. Call it with a few different values and print the results. SOLUTION CODE ------------- extends Node2D func _ready() -> void: print(calculate_damage(10, 1.5)) print(calculate_damage(20, 2.0)) print(calculate_damage(7, 0.75)) func calculate_damage(base: int, multiplier: float) -> int: return int(base * multiplier) OUTPUT ------ 15 40 5 WHY THIS WORKS AS AN ANSWER ---------------------------- The function signature matches the task exactly: a typed int parameter, a typed float parameter, and a typed int return value - so the editor would immediately flag it as an error if, say, a String were passed in by mistake. base * multiplier produces a float (int * float always promotes to float in GDScript, the same rule Python follows), so int(...) is needed to convert that float back down to a whole number before returning it - int() truncates toward zero rather than rounding, so 7 * 0.75 = 5.25 correctly becomes 5, not 6. That's what "rounded down" means here: any fractional part is simply dropped.