C Program to Print Following Output

Ads
 

C Program to Print Following Output

Hello Sir I wnat to print Followning output in C Language with for loop How I Can Print it?
5
5 4
5 4 3
5 4 3 2
5 4 3 2 1
View Answers

February 15, 2010 at 2:58 PM

Hi Friend,

Try the following:

#include <stdio.h>
#include <conio.h>
void main()
{
int i=0;
int j=0;
for (i=5; i >=1; i--){
for (j = 5; j >= i; j--)
printf(" %d",j);
printf(" \n");
}
getch();
}

Thanks

May 5, 2012 at 9:09 PM

4 3 4 2 3 4 1 2 3 4


May 5, 2012 at 9:09 PM

4 3 4 2 3 4 1 2 3 4

Ads









Related Tutorials/Questions & Answers:
C Program to Print Following Output - Development process
C Program to Print Following Output  Hello Sir I wnat to print Followning output in C Language with for loop How I Can Print it? 5 5 4 5 4 3 5 4 3 2 5 4 3 2 1  Hi Friend, Try the following: #include
How to print the following output using c program
How to print the following output using c program  1) 4 3 4 2 3 4 1 2 3 4 2) A B C D E F G H I J
Advertisements
C program to print the following
C program to print the following  Hello, Some one help me with a "C Program" to print the following as output: 4444444 4333334..., that is why I choosed Java Beginners, but please give me a C program
write a program in C to print following triangles on the screen
write a program in C to print following triangles on the screen  write a program in C to print following triangles on the screen
how to get following answer in turbo c program
how to get following answer in turbo c program  input 123456789 output 1 2 3 4 5 6 7 8 9
c programming..what wil be the output of this program
c programming..what wil be the output of this program   #include int main() { int arr[] = {0,1,2,3,4}; int i,*ptr; for (ptr=arr+4; ptr= arr; ptr--) { printf("%d",*ptr
how to get following output
how to get following output  input 123456 output 1 2 3 4 5 6
how to get following output
how to get following output  input 123456 output 1 2 3 4 5 6
Print the following format
Print the following format  how to print the following format given string "00401121" in java 0-** 1-* 2-* 3- 4
output of the program
output of the program  public static int sum(List list) { int sum = 0; for ( Iterator iter = list.iterator(); iter.hasNext(); ) { int i = ((Integer)iter.next()).intValue(); sum += i; } return sum
print array in following format
print array in following format  i want print two array in following... want output as: 1 2 3 11 12 13 4 5 6 14 15 16 7 8 9 17 18 19   Here is a code that displays the array values in the following pattern: 1 2
c program
c program  plz send me program for this. write a program to print the following code? (in c language) 1 2 3 4 5 6 7 8 9 10 1 2 3 4 5 6 7 8 9 10 11 2 3 4 5 6 7 8 9 10
ModuleNotFoundError: No module named 'c-print'
ModuleNotFoundError: No module named 'c-print'  Hi, My Python program is throwing following error: ModuleNotFoundError: No module named 'c... to install padas library. You can install c-print python with following command
C program
a function to print names of all students who joined in a particular year. (c)Write a function to print the data of a student whose roll number is given...C program  hi, here is my question: Create a structure to specify
how to print the following pattern
how to print the following pattern  Hello hEllo heLlo helLo hellO pls reply soon its an emergency   class StringPattern { public static void main(String[] args) { String st="hello
c program
c program  plz send me program for this. write a program to print the following code? 1 2 3 4 5 6 7 8 9 10 1 2 3 4 5 6 7 8 9 10 11 2 3 4 5 6 7 8 9 10 11 12 3 4
c++ program
c++ program  Write a program which reads a text from the keyboard and displays the following information on the screen in two columns: (a) Number of lines (b) Number of words (c) Number of characters Strings should be left
Write a java program that prints the decimal representation in reverse. (For example n=173,the program should print 371.)c
Write a java program that prints the decimal representation in reverse. (For example n=173,the program should print 371.)c  class rose { int n...); System.out.println("\nReverse the number"+i); S.out(); } }   print
printing the following output using for loop
printing the following output using for loop  1 2 3 3 4 5 4 5 6 7
printing the following output using for loop
printing the following output using for loop  1 2 3 3 4 5 4 5 6 7
program of c
program of c  write a program in c to display a to z without using printf or scanf statements or header files
program in c
program in c  Write a program that inputs five different integers from the keyboard, then print the sum, the product, the smallest and the largest of these numbers. Use only single selection form of if statement. For example: 1 3
C Program
C Program  Why doesn't the code int a = 1000, b = 1000; long int c = a * b; work? plz help me sir
c program
c program  How to convert binary digits to decimal number without using power function
c program
c program  WAP to show the area of a perimeter of a rectanglar by using input command
i want print the following out put
i want print the following out put  Hello sir i want the following out put can u provide the program in c# o/p; HELLOLLEH HELLLEH HELEH HEH H
write following program
write following program  Q1 What is the difference between single threaded application and multithreaded application? What are the benefits of multi... a no. If a no is even then print it else throw a user defined exception Q5 Draw
How to print the following pattern in java?
How to print the following pattern in java?  How to print the following pattern in java? he he is he is going he is going in   import java.io.*; class StringPattern { public static void main(String[] args
need a java program for the following
need a java program for the following  Write a java program with three horizontal sliders. Name the sliders, the first one as red, the second one as green and the third one as blue. You design the program such that on varying
core java code for following program
. The following are the guidelines while writing this program Only command line based...core java code for following program  We are hosting the Olympic games. Write a program that will track all the details of this hosting
method overloading in c program
method overloading in c program  how is method overloading in C program is different from C++ program

Ads