Skip to content

Commit 88ef56b

Browse files
author
“A1-4U2T1NN”
committed
fix: updated scale values;
1 parent 58193dd commit 88ef56b

File tree

1 file changed

+11
-11
lines changed

1 file changed

+11
-11
lines changed

lesson_07/conditionals/src/lesson7.ts

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -48,27 +48,27 @@ export function compareStrings(a: string, b: string): number {
4848
*/
4949
export function convertGpaToLetterGrade(gpa: number): string {
5050

51-
if(gpa > 4.0){
51+
if(gpa >= 3.9){
5252
return "A+"
53-
}else if(gpa >= 3.9){
54-
return "A"
5553
}else if(gpa >= 3.7){
56-
return "A-"
54+
return "A"
5755
}else if(gpa >= 3.3){
58-
return "B+"
56+
return "A-"
5957
}else if(gpa >= 3.0){
60-
return "B"
58+
return "B+"
6159
}else if(gpa >= 2.7){
62-
return "B-"
60+
return "B"
6361
}else if(gpa >= 2.3){
62+
return "B-"
63+
}else if(gpa >= 2.0){
6464
return "C+"
65-
}else if(gpa >= 2.0){
65+
}else if(gpa >= 1.7){
6666
return "C"
67-
}else if(gpa >= 1.7){
67+
}else if(gpa >= 1.3){
6868
return "C-";
69-
}else if(gpa > 1.3){
69+
}else if(gpa > 1.0){
7070
return "D+";
71-
}else if(gpa >= 1.0){
71+
}else if(gpa >= 0.7){
7272
return "D";
7373
}else{
7474
return "F"

0 commit comments

Comments
 (0)