Question: What is wrong with the following code snippet that checks if a person is tall enough to ride the rollercoaster? int height = 4 8
What is wrong with the following code snippet that checks if a person is tall enough to ride the rollercoaster?
int height ;
ifheight
boolean safe false;
System.out.printlnIs it safe to ride this rollercoaster? safe;
Nothing wrong
A variable name has a typo in it
A variable is accessed outside of its scope.
Brackets are not matched up
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
