...

Exercise: Speed Limits

You have been hired to build advanced software to support speed limit enforcement in police vehicles.

In this exercise, you'll create a speed limit violation system that determines the appropriate consequence based on how fast someone was driving.

The speed limit is set at 55. The system checks how much over the limit the driver was going, and outputs an appropriate message:

  • 55 or less: "Safe driving! No violation."
  • 56-60: "Just over the limit. Issue a warning."
  • 61-65: "Minor speeding violation. Issue a small fine."
  • 66-75: "Serious speeding! Issue a large fine."
  • 76+: "Major violation! Issue a hefty fine and consider suspending license."

Variables

No variables

Loading...

Output (Console)