Respuesta :
Well, you didn't say what language, so here's in Java:
public static void PrintShampooInstructions(int numCycles)
{
if(numCycles < 1)
System.out.println("Too few.");
else if (numCycles > 4)
System.out.println("Too many.");
else
{
for(int i = 1; i <= numCycles; i++)
{
System.out.println(i+": Lather and rinse.");
}
System.out.println("Done.");
}
}
And also in an image, in case you can't really see it

Answer:
public static void printShampooInstructions(int numOfCycles){
if(numOfCycles < 1){
System.out.println("Too few.");
}
else if(numOfCycles > 4){
System.out.println("Too many.");
}
else {
for(int index = 0; index < numOfCycles; ++index){
System.out.println((index + 1) + ": Lather and rinse.");
}
System.out.println("Done.");
}
}
Explanation:
