cari44
10-31-2006, 04:29 PM
Hi,
First of all, I'm very new to javascript but I do have knowledge of html. My boyfriend has a computer class and I told him I'd help him out as much as I can with his homework. Well, little did I know, I have no idea where to begin. I was able to complete the first question, but I'm now stuck here on the second.
So below is the question. I have no idea where to even begin. I know it may be too much to as for the whole code, but if anyone can point in a direction of where to start I'd be very thankful. Anything such as what type of code it is, where to look etc.. Thank you!
"Write a javascript funtion that converts a numerical grade to a letter grade. The write a program that continuously prompts the user for input. (The numerical grade), uses your function to convert the numerical grade to the letter grade and displays the letter grade on the screen until the user no longer wishes to continue. The user will click cancel when he doesn't want to continue.
You can assume the user will always use an integer but it may be any integer. If the user puts in an invalid numerical grade(such as a number less than 0 or greater than 100) the program should just put: Invalid Input.
Use this grading scheme:
85-100 = A
80-84 = A-
75-79 = B+
70-74 = B
65-69 = B-
60-64 = C+
55-59 = C
50-54 = D
0-49 = F
Once again, any help is appreciated! thanks
First of all, I'm very new to javascript but I do have knowledge of html. My boyfriend has a computer class and I told him I'd help him out as much as I can with his homework. Well, little did I know, I have no idea where to begin. I was able to complete the first question, but I'm now stuck here on the second.
So below is the question. I have no idea where to even begin. I know it may be too much to as for the whole code, but if anyone can point in a direction of where to start I'd be very thankful. Anything such as what type of code it is, where to look etc.. Thank you!
"Write a javascript funtion that converts a numerical grade to a letter grade. The write a program that continuously prompts the user for input. (The numerical grade), uses your function to convert the numerical grade to the letter grade and displays the letter grade on the screen until the user no longer wishes to continue. The user will click cancel when he doesn't want to continue.
You can assume the user will always use an integer but it may be any integer. If the user puts in an invalid numerical grade(such as a number less than 0 or greater than 100) the program should just put: Invalid Input.
Use this grading scheme:
85-100 = A
80-84 = A-
75-79 = B+
70-74 = B
65-69 = B-
60-64 = C+
55-59 = C
50-54 = D
0-49 = F
Once again, any help is appreciated! thanks