Question: In this assignment, you will write a program that creates patterns using for-loops given the size - an odd number between 7 and 15 (both

 In this assignment, you will write a program that creates patterns

using for-loops given the size - an odd number between 7 and

15 (both inclusive). This program - Asks for size (an odd number

In this assignment, you will write a program that creates patterns using for-loops given the size - an odd number between 7 and 15 (both inclusive). This program - Asks for size (an odd number between 7 and 15 (both inclusive)) - Validates that size is an odd number between 7 and 15 (both inclusive) See the first sample run to see validation. - Prints two patterns based on the given size. - Pattern 1: A pattern of as shown below in the sample programs. This pattern has as many lines as the size of the pattern (user input) with each line having 2 size +1 characters total. - Pattern 2: A pattern with mirror image made up of letter "A" (See sample runs below). Hint: Split the figure in top half and bottom-half parts, drawing them with two different for-loops. Look at each pattern closely and come up with a formula for the number of 'A's and number of spaces required on each row in the pattern. Add a comment block at the top of the file, providing your name, date, assignment name etc. Save the program to a file with a name of the format first_last_forloops.py and submit it as your solution. Sample run 1 with validation and size =7 Welcome to pattern generator Please enter the size of the patterns (an odd number between 7 and 15): -3 Size should be an odd number between 7 and 15 Please enter the size of the patterns (an odd number between 7 and 15): 8 Size should be an odd number between 7 and 15 Please enter the size of the patterns (an odd number between 7 and 15): 7 Pattern 1 of size 7 > Mirror image pattern of size 7 A A AA AA AAA AAA AAAA AAAA AAAAA AAAAA AAAAAA AAAAAA AAAAAAAAAAAAAA AAAAAA AAAAAA AAAAA AAAAA AAAA AAAA AAA AAA AA AA A A Python 3.8.1 Shell File Edit Shell Debug Qptions W Window H elp Please enter the size of the patterns (an odd number between 7 and 15): 9 Pattern 1 of size 9 > > Mirror image pattern of size 9 AA AAAA AAA AAA AAAA AAAA AAAAA AAAAA AAAAAA AAAAAA AAAAAAA AAAAAAA AAAAAAAA AAAAAAAA AAAAAAAAAAAAAAAAAA AAAAAAAA AAAAAAAA AAAAAAA AAAAAAA AAAAAA AAAAAA AAAAA AAAAA AAAA AAAA AAA AAA AA A A Bye >1

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!