Task: Question Decomposition
Input (English): question: What is the last name of the student who got a grade A in the class with code 10018.
Output (English): #1 return classes 
#2 return codes of #1 
#3 return #1 where #2 is equal to 10018 
#4 return students of #3 
#5 return grades of #4 
#6 return #4 where #5 is equal to A 
#7 return last name of #6