3.4.9 Battleships -
The core of the assignment involves a logic loop where attack power dictates health reduction: If attackPower < 4 : Health decreases by 3. If attackPower < 8 : Health decreases by 7. If attackPower >= 8 : Health decreases by 15.
: Initializes the ship with a name and attack power, setting initial health to 100. 3.4.9 battleships
The visual presentation in 3.4.9 is utilitarian but effective. The UI ditches the dated "pen and paper" aesthetic for a sleek, radar-like interface. The grid lines are crisp, making it easy to distinguish coordinates under pressure. The core of the assignment involves a logic
At its heart, 3.4.9 Battleships adheres to the traditional 10x10 grid format. Players arrange a fleet of varying sizes (from the sprawling Carrier to the nimble Destroyer) and take turns firing coordinates. However, where previous versions often felt stagnant during the "search phase," 3.4.9 introduces tighter mechanics regarding hit confirmation. The UI ditches the dated "pen and paper"
The turn structure is streamlined. There is a satisfying immediacy to the feedback: a miss produces a satisfying "splash," while a hit delivers a distinct visual cue. The standout mechanic remains the "Salvo" variant often enabled in this version, where players fire as many shots as they have remaining ships. This adds a layer of strategy often missing in the standard "single-shot" variant—losing a small boat isn't just a loss of health; it reduces your tactical output, forcing players to protect their smaller, harder-to-hit vessels with greater care.