Question: Please write out the code this is supposed to be. I got the code below and am unsure what I am doing wrong. Thank you
Please write out the code this is supposed to be. I got the code below and am unsure what I am doing wrong. Thank you
for i in range(1, 6): ....for j in range(1, 6): ........print(i, end='') ........print('', end='') ....print()
*I am using the period to indicate indentation*
3.16 Exercise: Write a program to print out consecutive integers in a diagonal, as in 1 2 3 4 5 Use a nested for-loop as in earlier examples to print the requisite number of spaces before printing a digit. Write your code in my_diagonal_print.py
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
