Skip to main content
1 of 2

A few remarks:

  1. Sleep duration is hard coded, it can be automatically calculated (depending on the text length).
  2. Display can be a function (including the sleep function).
  3. So you can just pass the string, it prints and waits.
  4. Instead of comparing the user input to Yes, yes and YES, you can simply compare the uppercase’d input to YES.