Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

python switch case 3.10

grade = 92
category = grade//10  # Well above average grade
match category:
	case 10:
		print("Excellent")
	case 9:
		print("Well above average")
	case 8:
		print("Above average")
	case 7:
		print("Average")
	case 6:
		print("Below average")
	case _:
		print("Not passing")
 
PREVIOUS NEXT
Tagged: #python #switch #case
ADD COMMENT
Topic
Name
5+4 =