1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Makovka662 [10]
2 years ago
10

Create a program that prompts the user for a positive integer then prints a right-aligned pyramid using that number using the st

ructure below
Here are some examples:

> Enter an integer between 1 and 5: 2
1
2 3
> Enter an integer between 1 and 5: 5
1
2 3
3 4 5
4 5 6 7
5 6 7 8 9

> Enter an integer between 1 and 5: -3.4
That's not an integer between 1 and 5.
Computers and Technology
1 answer:
Makovka662 [10]2 years ago
3 0

Below is the program that prompts the user for a positive integer then prints a right-aligned pyramid in python programming language.

rows = int(input("Enter number of rows: "))  

for i1 in range(1, rows):  

   for j1 in range(1, i1 + 1):  

       # This prints multiplication / row-column  

       print(i1 * j1, end='  ')  

   print()  

What is Python in programming?

Python is a interpreted, high-level programming, object-oriented, language with a dynamic semantics. Its high-level built-in data structures, combined with dynamic typing and dynamic binding, make it very appealing for Rapid Application Development, as well as for use as a scripting or glue language to connect existing components together.

Python's simple, easy-to-learn syntax emphasizes readability, lowering the cost of program maintenance. Python also supports modules as well as packages, which promotes program's modularity and reuse of code. The Python interpreter and extensive standard library are freely distributable and available in source or binary form for all major platforms.

To learn more about Python, visit: brainly.com/question/28379867

#SPJ1

You might be interested in
A restaurant bill comes to $28.35. Find the total cost if the tax is 6.25% and a 20% tip is left on the amount before tax.​
Salsk061 [2.6K]

Not sure how this is computers and technology

3 0
3 years ago
How is your mental health as you're returning to school virtually or in
kupik [55]

Answer:

My Answer is Below.

Explanation:

I have been experiencing stress, anxiety, fear, sadness and loneliness. And mental health disorders, including anxiety and depression, slowing it's going away once I get to talk to my friends and get to interact with others. Even though I get lots of anxiety from talking in public. I actually feel all of those hopefuls, exhausted, overwhelmed and more, because it's hard at home especially when my mom is really sick with brain cancer, since she was 12 yrs old now 40 yrs old. It's a lot to take in but I'm still trying.

Hopes this Helps :D

5 0
3 years ago
If num is an int which expression always evaluates to true if num holds an odd number
kherson [118]

num%2==1

The modulo operator (%) divides the left hand side by the right hand side and returns the remainder. When dividing an odd number by 2 there will always be a remainder of 1.

8 0
4 years ago
Please help!!!!!!! 50 POINTS!!!!
mrs_skeptik [129]

Answer:

A,D,C,B are the correct answers

Explanation:

Hope this helps:)

3 0
3 years ago
[PROGRAMMING] A ____ signal indicates that a specific amount of time should pass before an action starts.
Inessa [10]
A time signal will do that, I believe!
5 0
3 years ago
Other questions:
  • How has the development of personal computer hardware and software reversed some of the trends brought on by the industrial revo
    15·1 answer
  • Match the following tasks with their appropriate timing.
    8·1 answer
  • Collaborative devices are applications that allow users to work together even when they are in different locations.
    14·2 answers
  • Write a short Python function, is_multiple(n, m), that takes two integer values and returns True is n is a multiple of m, that i
    9·1 answer
  • Use pseudocode to specify a recursive algorithm to compute the nth value of the harmonic series, for some integer n.
    5·1 answer
  • John just opened a savings account and wants to maximize the amount of interest he ears. Which of the following actions
    8·1 answer
  • How to get the home button on your screen?
    13·1 answer
  • Which statement about bump mapping and normal mapping is true?
    9·1 answer
  • What is the common term used to describe a single computer document?
    15·2 answers
  • O
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!