You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
lavos/cap3/ex25.go

21 lines
394 B

7 months ago
package cap3
func Ex25(studentScore [][]int) int {
studentCount := 0
for _, scores := range studentScore {
scoreCount := 0
for _, score := range scores {
if score >= 90 {
scoreCount++
}
7 months ago
if scoreCount > 3 {
studentCount++
break
}
}
}
7 months ago
return studentCount
7 months ago
}