Question
JAVA:Imagine that you are driving and a police officer stops you. If speed is 60 mph or less, you get no ticket. If speed is
JAVA:Imagine that you are driving and a police officer stops you. If speed is 60 mph or less, you get no ticket. If speed is between 61 mph and 80 mph inclusive, you will get a small ticket. If speed is 81 mph or more, you will get a big ticket. However, on the day of your birthday you can go 5 mph faster in all cases. Write a java program that asks the user to enter the driving speed and whether it is your birthday and outputs: no ticket, small ticket, or big ticket depending on the input. Use the Scanner class for input and System.out.println for output.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started