Program to display given 3 integers in ascending order



Program to display given 3 integers in ascending order..

Answer / guest

1,2,3

Is This Answer Correct ?    16 Yes 9 No

Post New Answer

More C Interview Questions

In the following control structure which is faster? 1.Switch 2.If-else and which consumes more memory?

4 Answers  


Study the code: void show() main() { show(); } void show (char *s) { printf("%sn",s); } What will happen if it is compiled & run on an ANSI C Compiler? A)It will compile & nothing will be printed when it is executed B)it will compile but not link C)the compiler will generate an error D)the compiler will generate a warning

4 Answers   Accenture,


52.write a “Hello World” program in “c” without using a semicolon? 53.Give a method to count the number of ones in a 32 bit number? 54.write a program that print itself even if the source file is deleted? 55.Given an unsigned integer, find if the number is power of 2?

25 Answers   Datamatics, Solartis, TCS, ThinkBox, Trine,


write a program to print sum of each row of a 2D array.

4 Answers  


what will happen if you free a pointer twice after allocating memory dynamically ?

3 Answers   Novell,






5. What kind of sorting is this: SORT (k,n) 1.[Loop on I Index] repeat thru step2 for i=1,2,........n-1 2.[For each pass,get small value] min=i; repeat for j=i+1 to N do { if K[j]<k[min] min=j; } temp=K[i];K[i]=K[min];K[min]=temp; 3.[Sorted Values will be returned] A)Bubble Sort B)Quick Sort C)Selection Sort D)Merge Sort

2 Answers   Accenture,


Given an array of numbers, except for one number all the others occur twice. Give an algorithm to find that number which occurs only once in the array.

6 Answers  


Can we change the value of constant variable in c?

0 Answers  


what is the output? #define fun(a,b,t) (g ##t=(a),(a)=(b),(b)=g##t) float gfloat; main() { float a=1.12,b=3.14; fun (a,b,float); printf("na=%4.2f,b=%4.2f",a,b); } A)Error in Defining Macro B)a=1.12,b=3.14 C)a=3.14,b=1.12 D)None of the Above

3 Answers   Accenture, Infosys, Wipro,


What is dynamic memory allocation?

0 Answers  


What is the difference between abs() and fabs() functions?

0 Answers  


What is a 'null pointer assignment' error?

0 Answers  


Categories