While loop dragon slayer


finer details cant seem to be hard to find
Dragon slayer seems not that obvious to interpret even with the math coding.


Your code doesn't look quite right. Check the Hint if you need help!

var slaying = true;
var youHit = Math.floor(Math.random()*2)
var damageThisRound = Math.floor(Math.random()*5 + 1)
var totalDamage = 0;

    console("Die you mythical beast?")
        slaying = false


Its fine I solved it I just had to switch the values of slaying. And I passed to the next activity.:grinning:


and the " ; " should be added by the bottom "slaying" variable.


This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.