Is this what the task demands?


#1

if (computerChoice<=0.33) {
computerChoice="rock";
}
else if (computerChoice>0.33 &&
computerChoice<=0.66) {
computerChoice="paper";
}
else {
computerChoice="scissors";
}

is there more solutions to this task, or this is it?


#2

it's ok, I saw how codecademy did it in the following step.


#3

@y.t.w
Well, you can remove this

and the result will still be the same because if it was smaller or equal to 0.33 than it will have executed the code in the if statement and stop here. Otherwise, it will have continue to else if to see if it matches the condition.


#4

yeah thanks. didn't get that at the moment