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
Karo-lina-s [1.5K]
3 years ago
6

(1) The given program outputs a fixed-height triangle using a * character. Modify the given program to output a right triangle t

hat instead uses the user-specified triangle_char character. (1 pt) (2) Modify the program to use a loop to output a right triangle of height triangle_height. The first line will have one user-specified character, such as % or *. Each subsequent line will have one additional user-specified character until the number in the triangle's base reaches triangle_height. Output a space after each user-specified character, including a line's last user-specified character. (2 pts) Example output for triangle_char = % and triangle_height = 5:

Computers and Technology
1 answer:
zloy xaker [14]3 years ago
6 0

Answer:

Following are the code to this question can be described as follows:

c= input('Input triangle_char: ') #defining variable c that input character value  

length = int(input('Enter triangle_height: ')) # Enter total height of triangle

for i in range(length): # loop for column values

   for j in range(i+1): #loop to print row values

       print(c,end=' ') #print value  

   print()# for new line

Output:

please find the attachment.

Explanation:

In the above python code, two variable "c and length" variables are declared, in variable c is used to input char variable value, in the next line, length variable is defined, that accepts total height from the user.

  • In the next line, two for loop is declared, it uses as nested looping, in which the outer loop prints column values and inner the loop is used to prints rows.
  • To prints all the value the print method is used, which prints the user input character triangle.

You might be interested in
When a piece of shiny silver jewelry gets tarnished, what has happened?
makvit [3.9K]
A
because if you leave certain metals in the rain they tarnish or rust. think about how if you leave a bike in the rain for too long it will start to rust on the metal parts
6 0
3 years ago
Thanks to ____ files, a website can recognize you and cater to your individual tastes each time you visit.
Licemer1 [7]
Saved files now and days
4 0
4 years ago
What does a primary key allow a user to do in a database?<br><br> PLEASE HELP
NeTakaya

A primary key is the field (or fields) that is often employed to specifically identify each record in a table.

<h3>What is the role of this key?</h3>

The Primary key is known to be the key that helps a user to be able to form a specific identifier for each row in one's table.

Note that  it helps a person to link your table to other tables and as such, a  primary key is the field (or fields) that is often employed to specifically identify each record in a table.

Learn more about  primary key from

brainly.com/question/12001524

#SPJ1

5 0
2 years ago
Someone help pleaseee
kati45 [8]

Answer:

the área is 187

Explanation:

because you have to multiplicated base x height

the base is 17 and the height is 11

So the answer is 187

7 0
2 years ago
Which of the following terms describes a product that is designed to meet humans’ physical and/or psychological needs?
Readme [11.4K]
I think it is psychological needs
8 0
3 years ago
Read 2 more answers
Other questions:
  • In Python please:
    15·1 answer
  • (Palindrome integer) Write the methods with the following headers // Return the reversal of an integer, i.e., reverse(456) retur
    9·1 answer
  • Which of the following is another term for a subfolder?
    9·1 answer
  • In ______ each station is assigned a code; using a special coding scheme, stations send data over the entire bandwidth of the ch
    14·1 answer
  • When approaching a bicyclist from the rear, you should slow down and
    8·1 answer
  • What can provides access to the only menu in office 2007​
    13·1 answer
  • What is the standard unit used to measure mass?​
    9·1 answer
  • Choose the correct answer
    6·1 answer
  • A student can improve performance by decreasing
    14·1 answer
  • What are the real-life applications of coding?
    10·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!