In this classwork assignment, you are going to write a program that will calculate and return a student's current grade percentage. Also, the program will calculate how many additional points a student needs to receive a specific grade. The results should output on the browser for the student to read.
Push your code to your Github account and then paste the link to the repo when submitting. If you do not finish in class, submit what you were able to get done.
-
Remember that
prompt
output strings. How do you convert strings to numbers? -
Math.round()
will be needed in order to return a number that has been rounded to the nearest whole number. -
Use
document.write()
to display the sentences on the browser. -
Don't forget that you can use template literals which allows you to embed expression inside of a string.
-
Remember to use the
break
keyword in a switch statement which will ensure that the program breaks out of the switch once the matched statement has executed.
-
Use pseudocode to help you with creating a blueprint of the app before you start writing JavaScript.
-
Store the different prompts into variables.
-
Think about when you should use
let
orconst
. -
Use descriptive variable/ function names.