Already have an account? Get multiple benefits of using own account!
Login in your account..!
Remember me
Don't have an account? Create your account in less than a minutes,
Forgot password? how can I recover my password now!
Enter right registered email to receive password!
Write a C program to sort in ascending order of n numbers.
# include
void main()
{
int a[25],no,i,j,m,t;
clrscr();
printf("\nEnter Total number of inputs : ");
scanf("%d",&no);
printf("\nEnter %d number : ",no);
no--;
for(i=0;i<=no;i++)
scanf("%d",&a[i]); /* Enter array elements */
for(i=0;i<=no;i++) /* Number of Passes */
for(j=0;j /*Compare an element with the next element one by one*/ { if(a[j] { t=a[j]; /* Interchange the two if first is smaller */ a[j]=a[j+1]; a[j+1]=t; } } } printf("\n Sorted numbers are :\n"); for(i=0;i<=no;i++) printf("%d",a[i]); getch(); }
/*Compare an element with the next element one by one*/
if(a[j] { t=a[j]; /* Interchange the two if first is smaller */ a[j]=a[j+1]; a[j+1]=t; } } } printf("\n Sorted numbers are :\n"); for(i=0;i<=no;i++) printf("%d",a[i]); getch(); }
t=a[j]; /* Interchange the two if first is smaller */
a[j]=a[j+1];
a[j+1]=t;
}
printf("\n Sorted numbers are :\n");
printf("%d",a[i]);
getch();
how create database design for pharmacy by diagram and query
How optimization is achieved in DNS? Two primary optimizations used in DNS and they are: replication and caching. All root servers is replicated; various copies of the server
What are the four significant factors that led to the development of open source software? 1. To diminish the high control value of the Proprietary Software 2. To avoid disc
Serial Execution Execution of a program serially, one statement at one instance of time. In the simplest case, that's what takes place on a one processor machine. But even mo
How will this difference b interpreted? When one pointer is subtracted from another pointer, the number of elements between the two pointers always includes the element pointed
The declaration tells the compiler that at some later point we plan to show the definition of this declaration. E.g.: void stars () //function declaration The definition con
What is a Match Code? Match code is a tool to help us to find for data records in the system. Match Codes are an proficient and user-friendly search aid where key of a record i
We might model such a scenario using three types of object: one for Customers, one for BankAccounts and another for Transactions. In terms of data required, for Customers assume we
Using each connected device is assigned a time slot whether or not the device has anything to send. (A) WDM (B) FDM
The six several application of stack in computer application is: 1. Conversion of infix to postfix notation and vice versa. 2. Evaluation of arithmetic expression. 3.
Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!
whatsapp: +91-977-207-8620
Phone: +91-977-207-8620
Email: [email protected]
All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd