Javatpoint Logo
Javatpoint Logo

Program to print the following pattern


  1. Start
  2. Let i be an integer number.
  3. Let j be an integer number.
  4. Let n be a integer number and initialize by 1.
  5. Repeat step 6 to 9 until all value parsed.
  6. Set i = 0 and check i<6;
  7. Set j = 1 and check j <= i;
  8. Print number n.
  9. Then n++;
  10. End

In this program, we are creating a right-angled triangle of numbers in increasing order. We are creating two loops, and 2nd loop is executing according to the first loop, inside 2nd loop printing the number row-wise i loop times.

2 3
4 5 6
7 8 9 10



C program

C# program

PHP program

Youtube For Videos Join Our Youtube Channel: Join Now


Help Others, Please Share

facebook twitter pinterest

Learn Latest Tutorials


Trending Technologies

B.Tech / MCA