Професионална програма
Loading...
+ Нов въпрос
Iv_Konov avatar Iv_Konov 385 Точки

Здравей,

 

Пробвай да редактираш кода по долния начин.

Може да провериш и този пост за справка (той е за C# обаче):

https://softuni.bg/forum/26070/problem-with-high-jump-from-programming-basics-online-exam-9-and-10-march-2019

 

if(counterHeight >= heightDesired)

===========================

  1. if(jumps > heightDesired){

  2.         console.log(`Tihomir succeeded, he jumped over ${heightDesired}cm after ${counterSuccess+counterUnsuccess} jumps.`);

  3.     }else{

  4.         console.log(`Tihomir failed at ${counterHeight}cm after ${counterSuccess+counterUnsuccess} jumps.`);

  5.     }

0