Input (grade 4): After they have molted four times (i.e., in the fifth instar), their bodies turn slightly yellow and their skin becomes tighter.
Output (grade 9): After they shed four times, their bodies turn slightly yellow and their skin becomes tighter, which means they are going to become a pupa.