Question: I need help writing this program in java, it has to look exactly like the sample output. Write a program which asks the user for

I need help writing this program in java, it has to look exactly like the sample output.

Write a program which asks the user for an integer and then prints the following patterns based on that integer.

Input Validation:

For Pattern 1, the input must be a value between 1 and 999.

For Pattern 2, the input must be a value between 1 and 26.

Requirements:

For Pattern 1: must be able to work with up to three digit numbers. You will want to use printf to get the spacing correct.

For Pattern 2: make note of what is uppercase and what is lowercase.

You must use (for) loops to solve this problem.

Program must be dynamic and work for any of the valid input values. You CANNOT hardcode the output.

HINT: You will need to use nested loops for this one. Each pattern is its own set of nested loops.

Sample Execution:

How many rows for Pattern 1?: 10 10 10 9 10 9 8 10 9 8 7 10 9 8 7 6 10 9 8 7 6 5 10 9 8 7 6 5 4 10 9 8 7 6 5 4 3 10 9 8 7 6 5 4 3 2 10 9 8 7 6 5 4 3 2 1 How many rows for Pattern 2?: 26 A b C d E f G h I j K l M n O p Q r S t U v W x Y z A b C d E f G h I j K l M n O p Q r S t U v W x Y A b C d E f G h I j K l M n O p Q r S t U v W x A b C d E f G h I j K l M n O p Q r S t U v W A b C d E f G h I j K l M n O p Q r S t U v A b C d E f G h I j K l M n O p Q r S t U A b C d E f G h I j K l M n O p Q r S t A b C d E f G h I j K l M n O p Q r S A b C d E f G h I j K l M n O p Q r A b C d E f G h I j K l M n O p Q A b C d E f G h I j K l M n O p A b C d E f G h I j K l M n O A b C d E f G h I j K l M n A b C d E f G h I j K l M A b C d E f G h I j K l A b C d E f G h I j K A b C d E f G h I j A b C d E f G h I A b C d E f G h A b C d E f G A b C d E f A b C d E A b C d A b C A b A 

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!