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!
Shell sort - C Program:
Write a program to define shell sort.
void main()
{ //program for sorting by select sort
int a[20],i,k,j,n;
clrscr();
printf("How many nos are to be sorted\n");
scanf("%d",&n);
for (i=0;i<=n-1;i++)
{
printf("Enter the value of %d no\t",i+1);
scanf("%d",&a[i]);
}
printf("Make sure !Are your values read correctly?\n");
printf("%d \n",a[i]);
for (i=0;i<=n-1;i++) //In select sort we consider the 1 st element &
for (j=i+1;j<=n-1;j++) //compare it with the remaining in the 1st step
{ //&swaping is done next considering 2nd element etc.
if (a[i] >= a[j])
k=a[i];
a[i]=a[j];
a[j]=k;
printf("The sorted data is\n");
for (j=0;j<=n -1;j++)
printf("%d\n",a[j]);
getch();
Define How Passing Arrays to a Function? A complete array can be passed to a function as an argument. The manner in which the array is passed be different from that of an ordin
What is the difference between structure and class? - Members of structures are public while those of a class are private. - Classes provide data hiding while structures don
What happens if you write following code? string& foo()
Node *orderedInsert(Node *p, int newval); /* Allocates a new Node with data value newval and inserts into the ordered list with first node pointer p in such a way that the data va
write a atm program in c with inbuilt functions for 1782?
Program is to replace every occurrence of in a string: Program is to replace every occurrence of c1 in string with c2 and have function return the no. of replacement int re
Write a program called A1Q3, that reads it the radius of a circle as an integer and prints the circle's diameter, circumference and area. Use a constant value for pi. Do all calc
Write a program to sort an array of strings. Use new and delete operators. Write a program to find the factorial of a number using recursion. If we do not accept the number
find area under the curve y=f(x) between x=a &y=b integrate y=f(x)
Write a C program to calculate the output Y for a given value of X for the following formula Y=X 2 + 2X +3 #include stdio.h void main() { char promt; float y,x
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