In the US both are used, but "get" may be used a bit more often. I feel a slight difference in meaning, with "get" being more current (What grade did you get on the math test?) and "have" being more related to what grades were achieved over time (What kind of grades did you have in college?). Both are accepted for this sentence.
In a little more detail. Historically "get" was seen as less formal or less educated than "obtain" or "receive". So, for example, if you asked for your school for a listing of your grades (UK English "marks"), the formal letter would use "obtained" or "received" rather than "got". In spoken language though, the use of "obtained" or "received" out of a formal situation is likely to be seen as pompous.