Flash Mobs for Hope

Challenge
No

Mary Louise Porter runs Flash Mobs for Hope, small flash mobs that sing at farmer's markets and such. Write a program to help Mary work out the cost of supplies for an event.

To help the singers relax before a gig, she gives them small packs of special gummies. The number of gummies depends on the type of singer:

  • Sopranos are flighty. They get three packs each.
  • Altos aren't as bad, but being soprano-adjacent, they need extra. They get two packs each.
  • Tenors and basses are rock solid. They get one pack each.

The price of a pack depends on the number MLP orders.

  • 20 or more packs: $8.50 each
  • 10 to 19: $8.80 each
  • Less than 10: $9.10 each

Shipping is free if MLP orders 25 or more packs. Otherwise, shipping is $0.50 per pack.

If there are too many sopranos, they get over-excited. Sometimes they need to be tranquilized. MLP's assistant Wendell has a dart gun for those cases.

If there are more sopranos than all the others put together, output a message saying Wendell should bring the dart gun. He'll need two more darts than the number of sopranos. He's a good shot, but they run around when excited.

Here's some sample I/O:

  • Flash Mobs for Hope
  • -------------------
  •  
  • How many sopranos? 1
  • How many altos? 1
  • How many tenors? 1
  • How many basses? 1
  •  
  • Gummy packs needed: 7
  • Gummies price: 63.7
  • --------------------
  • Total: 67.2

Another sample:

  • Flash Mobs for Hope
  • -------------------
  •  
  • How many sopranos? 5
  • How many altos? 2
  • How many tenors? 1
  • How many bass? 1
  •  
  • !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
  • WARNING! Too many sopranos!
  • Have Wendell bring the dart gun with 7 darts.
  • !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
  •  
  • Gummy packs needed: 21
  • Gummies price: 178.5
  • --------------------
  • Total: 189.0

Other things:

  • Assume users make no input errors. That's later in the course.
  • Round numbers to at most two decimal places.
  • Add comments for IPO.
  • Format the output exactly, with the blank lines, underlining, etc.

Upload your solution here, not to Moodle. The usual coding standards apply.