C Program to Print Consecutive Column Numbers in Right Triangle

In this tutorial you will learn about the C Program to Print Consecutive Column Numbers in Right Triangle and its application with practical example.

C Program to Print Consecutive Column Numbers in Right Triangle

In this tutorial, we will learn to create a C program that will print Consecutive Column Numbers in Right Triangle in C programming.

Prerequisites

Before starting with this tutorial, we assume that you are the best aware of the following C programming topics:

  • Operators in C Programming.
  • Basic Input and Output function in C Programming.
  • Basic C programming.
  • For loop in C programming.

Algorithm:-

Program description:-

In today’s program, we will first take the input rows from the user. Then we will print the Consecutive numbers from 1 to ending using the for a loop.  Then we will print the right angle triangle pattern filled with the Consecutive Numbers.

The Consecutive pattern means the printing of data in a sequential format, one time it returns 1, and the next time 2 then 3, and so on. The Consecutive pattern triangle contains numbers from 1 to the satisfying point.

The below is an example of the right triangle pattern program code filled with Consecutive numbers in the Column.

Program Code:-

Output:-

In the above program, we have last initialized the required variable.

 

  • rw = it will hold the integer value.
  • k = it will hold the integer value.
  • j = it will hold the integer value.
  • i = it will hold the integer value.

Input the number of rows for the pattern.

Code to make the print Consecutive Row Numbers in Right Triangle.

Printing Consecutive Row Numbers in Right Triangle.

In this tutorial we have learn about the C Program to Print Consecutive Column Numbers in Right Triangle and its application with practical example. I hope you will like this tutorial.