find all occurrences of an element in a list python

student_grades = [9.1, 8.8, 10.0, 7.7, 6.8, 8.0, 10.0, 8.1, 10.0, 9.9]

samebnumber = student_grades.count(10.0)

print(samebnumber)

Here is what the above code is Doing:
1. We created a list of student grades.
2. We created a variable called samebnumber and assigned it the value of the number of times the number 10.0 appears in the list.
3. We printed the value of the samebnumber variable.