Help with the exercise in JavaScript

Call me dumb idc,but can someone explain me this…? I did the exercise but i don’t undertsand it at all.

Complete the JavaScript code block that checks if an employee has earned at least 75 points. The variable containing the value 75 should not be modified once assigned.

const bar = 75;
let employee1Points = 72;

employee1Points = employee1Points + 5;
if (employee1Points >= bar)
{ console.log(‘You are a super active employee!’); }

so employee1points should be 77 right?
so what is if (employee1points>=bar) ?

Hello @design1389826683!

Yes, after this line:

It is now equal to 77.

if (employee1points>=bar) checks to see if the value stored in the variable employee1points is greater than, or equal to, the value stored in the variable bar.
I hope this helps!

1 Like

@codeneutrino it does! and thanks for your help. And i didn’t get the if ,
im actually just going over if,else if and else lessons so i couldn’t get it before…

1 Like