Task: Question Decomposition
Input (English): question: Group by ships by flag, and return number of ships that have each flag.
Output (English): #1 return ships  
#2 return flags of #1 
#3 return number of  #1 for each #2