Get Grade using function