Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Hi i need help with this. Please DON'T USE LOOPS. Thank you! Question 3. Print a parallelogram of the letters of a five character word
Hi i need help with this. Please DON'T USE LOOPS. Thank you!
Question 3. Print a parallelogram of the letters of a five character word Write a program which prints a 5 letter word (I have used 5 letter names in my examples) in the form of a parallelogram as in the examples below. Nine lines of the output print sections of the word, the first line prints the first letter of the word, the next line prints the next two letters of the word, etc., the fifth line prints the whole word and the next three lines contract the word until the last line which prints just the last letter of the word. Each of these 9 lines is indented by four spaces and the whole nine lines are enclosed inside four rows of stars. Each row of stars is indented by two spaces. Copy the following statement into the start of your program. word = "MARIA" You can assume that the word always has five letters. Write your program in a file named YourUsernameA103.py", e.g., afer023A123.py. Below are two example outputs from the completed program (using a different value for the initial variable). Your program must give the correct output in the same format as the outputs in the two examples below: AM AME AR ARI ARIA MARTA ARIA AMES JAMES AMES MES ES RTA Once you are happy that your program code executes correctly, copy all the program code into CodeRunner except for the initial statement which initialises the variable and press the 'Check" buttonStep 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