C programming concepts

C programming made easy.

Menu

  • Home
  • C programming basics
  • Functions
  • Pointers
  • Arrays
  • Strings
  • Unions
  • Structures
  • DMA
  • Queue
  • Stack
  • Linked list
  • Binary tree
  • Binary search tree
  • Threaded binary tree
  • AVL Tree
  • Heap
  • Graphs
  • Sorting
  • Searching

Saturday, 11 June 2016

Floyd's Triangle




#include<stdio.h>

int main()
{
    int i,j,n,no=1;

    printf("Enter no of rows ");
    scanf("%d",&n);

    for(i=1;i<=n;i++)
    {
         printf("\n");

         for(j=1;j<=i;j++)
         {
             printf("%d ",no);
             no++;
         }
    }

    return 0;
}
Posted by anonymous at 06:50
Email ThisBlogThis!Share to XShare to FacebookShare to Pinterest
Labels: basic programs, C programming

No comments:

Post a Comment

Newer Post Older Post Home
Subscribe to: Post Comments (Atom)

Give us a thumbs up !!!

PAGES

  • Home
  • C programming basics
  • Functions in C
  • Pointers in C
  • Arrays in C
  • Strings in C
  • C Unions
  • Structures in C
  • Stack
  • Queue
  • Dynamic Memory Allocation
  • Linked list
  • Binary Tree
  • Binary Search Tree
  • Threaded Binary Tree
  • AVL Tree
  • Binary Heap
  • Graphs in C
  • Sorting Algorithms
  • Searching Algorithms

POSTS

  • ►  2017 (1)
    • ►  June (1)
  • ▼  2016 (24)
    • ▼  June (24)
      • Number pattern 3
      • Star Diamond
      • Find number is odd or even
      • Pascal's triangle
      • Floyd's Triangle
      • Star triangle
      • Letter pattern
      • Number pattern 2
      • Number pattern 1
      • Print characters for corresponding ascii values
      • Swap 2 numbers
      • Reverse a number
      • Check a string is palindrome without using library...
      • Smallest number in array
      • Largest number in array
      • Greatest of 3 numbers
      • Fibonacci Series
      • Print prime numbers in a given range
      • Check given number is prime
      • Check given year is leap year
      • Check given number is armstrong number
      • Sum of digits of a number
      • Factorial of a number
      • Sum of natural numbers in a given range
Simple theme. Powered by Blogger.