Question: Using JAVA, write methods that print the following patterns to the console such that their size depends on a passed-in integer argument. Part a) This

Using JAVA, write methods that print the following patterns to the console such that their size depends on a passed-in integer argument. Part a) This first shape is a triangular pattern with sides of 6 asterisks. The call that produces this pattern is shape7a. Your code should work for any positive integer. Here is an example with the integer 6 being passed in: * * * * * * . * * * * * . . * * * * . . . * * * . . . . * * . . . . . * Part b) This second shape is an X pattern with arms of 3 asterisks each. The call that produces this pattern is shape7b.Your code should work for any positive integer. Here is an example with 7 being passed in: * . . . . . * . * . . . * . . . * . * . . . . . * . . . . . * . * . . . * . . . * . * . . . . . *

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!