ctrl-shift-j brings up the browser error log, this has things you can click on to highlight the line that caused the crash, e.g. :-
if percentage < 70
You don't have brackets around your conditionals. These are 100% required. For each if statement it needs all the conditions between a pair of () brackets. These brackets must match, and tell the program what things belong to that if statement.
You can't do if (x==1) || (x==2) either, since only the first set of brackets will be understood as belonging to the if statement. You could do one of these instead:
if ( (x==1) || (x==2) )
or just
if ( x==1 || x==2 )
You can also nest conditions to indicate how the logic works:
if ( (percentage > 70 && class=top ) || iamrich = true)
grade = highdistinction;
^ this would give the "highdistinction" grade if the person got over 70 and was in the top class, OR if they were rich, regardless of grades. if the brackets went the other way:
if ( percentage > 70 && (class=top || iamrich = true) )
grade = highdistinction;
This would give the highdistinction to anyone who got over 70%, but only if they were either in the top class OR rich. I hope this example gives you an insight into how to code your thought process into the if statements. When you have any doubt about the order of operations, throw brackets around the individual conditonals. The only time you will 100% certain you don't need them is when all connectors are either AND or OR, since it won't matter then what order they are evaluated.
I'd also caution always using c-style semi-colons at the end of lines that need them. If you get into the habit of leaving them off, this will fuck you over when you try and learn other c-style languages. Very few are as forgiving as JavaScript.