using nested loopsto create a pattern

You program will get the width of the base of the triangle from the user. You should onlyneed a fewcout statementstoactually buildthe triangle. Depending on how you do this you may four or five cout statements, but you must not just have
77 cout statements. You should be figuring out how do this the programmatically or
any positive value.
You will need to have several functions in
addition to your main function. The main will call the other
functions. You will need to have a function to read in the width of the base of the triangle. This function
must ensure that the value of the width is between 4 and 80. If the width is not, the u
ser must be asked
to enter in a new value. This will continue until the user enters a value between 4 and 80, inclusive.
You will need another function to actually build and display the triangle.

Topic archived. No new replies allowed.