When you come across an unresponsive patient, the next step is:
Shouting and shaking is checking for responsiveness: The patient is already described as unresponsive, i.e., not responding to shouts or shakes.
The next step in an unresponsive patient is to check for carotid pulsations; if not palpable, consider that the patient is in cardio-respiratory arrest and immediately initiate CPR.
CPR is initiated as Circulation -> Airway -> Breathing (CAB), not ABC any longer.
Shout and shake the patient
Check for carotid pulsations
Secure the airway
Start chest compressions