Answer Posted / ansar husain
void main()
{
int A[50];
int n,j,t ;
printf("enter the size of array:=>");
scanf("%d",&n);
printf("enter the %d value in array:=>%d",n);
for(i=0;i<n;i++)
{
for(j=0;j<n;j++)
{
if(A[i]>A[j])
{
i=a[i];
A[i]=a[j];
A[j]=t;
}
}
}
printf("after the shorting:=>\n");
for(i=0;i<n;i++)
{
printf("%d",A[i]);
}
getch();
| Is This Answer Correct ? | 1 Yes | 6 No |
Post New Answer View All Answers
what is associativity explain what is the precidence for * and & , * and ++ how the folloing declaration work 1) *&p; 2) *p++;
What is difference between constant pointer and constant variable?
Why doesnt the call scanf work?
How many identifiers are there in c?
What are the 5 types of inheritance in c ++?
What are local variables c?
In c language can we compile a program without main() function?
Was 2000 a leap year?
How can I read in an object file and jump to locations in it?
cin.ignore(80, _ _);This statement a) ignores all input b) ignores the first 80 characters in the input c) ignores all input till end-of-line d) iteration
main() { inta=10,b=20; a>=5?b=100:b=200; printf("%d ",b); }
Explain what are the standard predefined macros?
Can we change the value of #define in c?
What are the application of c?
What is the difference between pure virtual function and virtual function?