Examples · learn/03-functions · 91 of 339
task-3.solution
tin run examples/learn/03-functions/task-3.solution.tinfn grade(score: int): string {
if score >= 90 { "A" }
else if score >= 75 { "B" }
else { "C" }
}
fn main() {
print(grade(95))
print(grade(80))
print(grade(40))
}