Revision
So you think you can count
Round and other functions
Revision and practice
26. Exercise 3

Instruction

Nice! What about the next exercise?

Exercise

Each warrior at level 3 or higher can perform a special attack whose damage is calculated as follows: its strength plus one fourth of its hp, and then multiplied by stat_modifier. If the stat_modifier is a negative number, its absolute value is taken. Round this column to 2 decimal places.

Show the name and special attack damage (column damage) calculated for those characters which have the attack available.

Console

Code editor

Result

TableConsole