Answered step by step
Verified Expert Solution
Question
1 Approved Answer
LAB REQUIREMENTS 1. Make sure you have a green check in Grader for this lab. 2. Add comments to the top of your program: first
LAB REQUIREMENTS 1. Make sure you have a green check in Grader for this lab. 2. Add comments to the top of your program: first three comment lines must have: 1) your name, 2) COMP 171 and section no., and 3) Lab \# 3. Upload your Java program here (.java file). 4. Deadline is soft. Try to stick to the deadline to manage your time. You can submit labs later, without penalty. However, all labs are due no later than the last day of the semester. LAB GRADE: either 25 (complete) or 0 (incomplete) Problem: How many days? Description: 3.11 (Find the number of days in a month) Write a program that prompts the user to enter the month and year and displays the number of days in the month. For example, if the user entered month 2 and year 2012, the program should display that February 2012 had 29 days. If the user entered month 3 and year 2015 , the program should display that March 2015 had 31 days. Remember, create only ONE Scanner object to accept all inputs from the user. Program name: Lab03.java Sample Runs: Enter the month (1-12): 3 Enter the year (yyyy): 2019 March 2019 had 31 days Enter the month (1-12): 12 Enter the year (yyyy): 2021 December 2021 had 31 days
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