Suppose that data is an array of 1000 integers. Write a single function call that  will sort the 100 elements data [222] through data [321].

1 Answer

Answer :

quicksort ((data + 222), 100)

Related questions

Description : Write a program to sort elements of an array in ascending order.

Last Answer : #include #include void main() { int a[5],i,j,temp; clrscr(); printf("\n Enter array elements:"); for(i=0;i

Description : Suppose list1 is [2, 33, 222, 14, 25], What is list1[:-1] ? a) [2, 33, 222, 14]. b) Error c) 25 d) [25, 14, 222, 33, 2].

Last Answer : a) [2, 33, 222, 14].

Description : Suppose list1 is [2, 33, 222, 14, 25], What is list1[-1] ? a) Error b) None c) 25 d) 2

Last Answer : c) 25

Description : How can you sort the elements of the array in descending order?

Last Answer : By calling Sort() and then Reverse() methods. 

Description : How can you sort the elements of the array in descending order? 

Last Answer : By calling Sort() and then Reverse() methods.

Description : What is the sum of the integers 100 to 1000?

Last Answer : Need answer

Description : What does the following declaration mean ? int (*ptr) [10]; (A) ptr is an array of pointers of 10 integers. (B) ptr is a pointer to an array of 10 integers. (C) ptr is an array of 10 integers. (D) none of the above.

Last Answer : (B) ptr is a pointer to an array of 10 integers.

Description : Which recursive sorting technique always makes recursive calls to sort subarrays that are about half size of the original array?

Last Answer : Mergesort always makes recursive calls to sort subarrays that are about half size of the original array, resulting in O(n log n) time.

Description : Write a program to sort an 1-d array in ascending order.

Last Answer : #include<iostream.h> #include<conio.h> void main() { int arr[20]; int i, j, temp,n; clrscr(); cout<<"\n Enter the array size:"; cin>>n; cout<<"\n Enter ... 0;i<n;i++) {  cout<< \n <<arr[i]; } getch(); }

Description : Accept data for five students and display it. Write a C++ program to displya sum of array elements of array size n. 

Last Answer : #include<iostream.h> #include<conio.h> void main() { int arr[20],i,n,sum=0; clrscr(); cout<<"\nEnter size of an array:"; cin>>n; cout<<"\nEnter ... ; } cout<<"\nSum of array elements is:"<<sum; getch(); }

Description : Suppose that the time to do a null remote procedure call (RPC) (i.e, 0 data bytes) is 1.0 msec, with an additional 1.5 msec for every 1K of data. How long does it take to read 32 K from the file server as 32 1K RPCs? (A) 49 msec (B) 80 msec (C) 48 msec (D) 100 msec

Last Answer : (B) 80 msec

Description : Which of the following algorithms sort n integers, having the range 0 to (n2 -1), in ascending order in O(n) time ? (A) Selection sort (B) Bubble sort (C) Radix sort (D) Insertion sort

Last Answer : (C) Radix sort

Description : If there are n integers to sort, each integer has d digits and each digit is in the set {1,2, ..., k}, radix sort can sort the numbers in: (A) O(d n k) (B) O(d nk) (C) O((d+n)k) (D) O(d(n+k))

Last Answer : (D) O(d(n+k))

Description : The primary turns of a 444 V/222 V, 50 Hz single-phase transformer with a core cross-sectional area of 100 cm2, and a maximum flux density of 1.0 T is (A) 100 (B) 200 (C) 222 (D) 400

Last Answer : The primary turns of a 444 V/222 V, 50 Hz single-phase transformer with a core cross-sectional area of 100 cm2, and a maximum flux density of 1.0 T is 200

Description : oy was playing with a book and tore out pages 7, 8, 100, 101, 222 and 223. How many pages did he tear out?

Last Answer : 5 pages

Description : How do you write 8211 321 400 in words?

Last Answer : 8 211 321 400

Description : How many integers between 1000 and 9999 are even digits?

Last Answer : Need answer

Description : If the given input array is sorted or nearly sorted, which of the following algorithm gives the best performance? a) Insertion sort b) Selection sort c) Quick sort d) Merge sort

Last Answer : a) Insertion sort

Description : Which of the following describes a relational database? 1) It provides a relationship between integers 2) It consists of separate tables or related data 3) It retrieves data related to its queries 4) It provides a relationship between floats

Last Answer : 2) It consists of separate tables or related data

Description : When the celebrated German mathematician Karl Friedrich Gauss (1777-1855) was nine he was asked to add all the integers from 1 through 100. He quickly added 1 to 100, 2 to 99, and so on for 50 pairs ... 1,000,000,000.That's all the digits in all the numbers, not all the numbers themselves. -Riddles

Last Answer : The numbers can be grouped by pairs: 999,999,999 and 0; 999,999,998 and 1' 999,999,997 and 2; and so on.... There are half a billion pairs, and the sum of the digits in each pair is 81. The digits in the unpaired number, 1,000,000,000, add to 1. Then: (500,000,000 X 81) + 1= 40,500,000,001.

Description : When an array is passed as parameter to a function, which of the following statements is correct ? (A) The function can change values in the original array. (B) In C, parameters are passed by value, ... . (D) Results in a run time error when the function tries to access the elements in the array.

Last Answer : (A) The function can change values in the original array.

Description : Write a C++ program to accept array of five elements, find and display smallest number from an array.

Last Answer : #include<iostream.h> #include<conio.h> void main() { int a[5],smallest,i; clrscr(); cout<<" Enter array elements:"; for(i=0;i<5;i++) cin>>a[i] ... } } cout<<endl<<"Smallest number="<<smallest; getch(); }

Description : Write a program to compute the sum of all elements stored in an array using pointers.

Last Answer : #include #include void main() { int a[5],sum=0,i,*ptr; clrscr(); printf("\n Enter array elements:"); for(i=0;i

Description : Which processor has a single instruction multiple data stream organization that manipulates the common instruction by means of multiple functional units. a. Attached array processor b. SIMD array processor c. Both d. None

Last Answer : b. SIMD array processor

Description : To accept 100 different values into the array we require A) Loop B) If condition C) Function D) Structure

Last Answer : A) Loop

Description : How many write cycles are allowed to a RAM? 1) 1 2) 10 3) 100 4) 1000

Last Answer : 1) 1

Description : How many write cycles are allowed to a EEPROM ? 1) 1 2) 10 3) 100 4) 1000

Last Answer : 4) 1000

Description : How many pluses should we put between the digits of 987,654,321 to get a total of 99, and where? -Riddles

Last Answer : (6) 9 + 8 + 7 + 6 + 5 + 43 + 21= 99 (7) 9 + 8 + 7 + 65 + 4 + 3 + 2 + 1= 99

Description : Why did this happen to me ? I struggled a lot with 320 questions and 321 answers with 960 and monthly guru points were 982. Now why did my points decrease ? I want a solution.

Last Answer : Did you answer a question incorrectly ? If not, why did you cut your points ?

Description : Calculate the resistance of a 2 m long nichrome wire of radius 0.321 mm. Resistivity of nichrome is `15xx10^(-6) Omega` m. If a potential difference o

Last Answer : Calculate the resistance of a 2 m long nichrome wire of radius 0.321 mm. Resistivity of nichrome is ` ... wire, what will be the current in the wire ?

Description : What is 332 divided by 321?

Last Answer : 1.0343

Description : What is 2 756 321 rounded off to the nearest million?

Last Answer : If you mean 2,756,321 then it is 3,000,000 rounded to thenearest million

Description : What is 121 is increased 321?

Last Answer : It is 442.

Description : How do you do 121 is increased to 321?

Last Answer : Add 200 to it because 121 plus 200 = 321

Description : How do you use a 321 organizer?

Last Answer : What is the answer ?

Description : What is the partial product of 8 times 321?

Last Answer : 2400 + 160 + 8

Description : Round to nearest ten thousand 65,321?

Last Answer : 64000

Description : In 321 BC Chandragupta founded the Mauryan Empire, which was centred in modern in Pakistan but had its capital far to the east at: A. Asaam B. Calcutta C. Delhi D. Patna

Last Answer : ANSWER: D

Description : The Mauryan Empire was founded in: A. 361 BC B. 301 BC C. 319 BC D. 321 BC

Last Answer : ANSWER: D

Description : The Constitution of India provides for an Election Commission under Article - (1) 321 (2) 322 (3) 323 (4) 324

Last Answer : (4) 324 Explanation: Constitution of India provides for an election commission under article 324. Article 321 empowers power to extend functions of Public service commission. Under article 322 expenses of public service commission mentioned.

Description : Assuming that the disk head is located initially at 32, find the number of disk moves required with FCFS if the disk queue of I/O block requests are 98, 37, 14, 124, 65, 67: (A) 310 (B) 324 (C) 320 (D) 321

Last Answer : (D) 321

Description : If the Disk head is located initially at track 32, find the number of disk moves required with FCFS scheduling criteria if the disk queue of I/O blocks requests are: 98, 37, 14, 124, 65, 67 (A) 320 (B) 322 (C) 321 (D) 319

Last Answer : (C) 321

Description : PDA stands for (1) Personal Digital Assistant (2) Personal Development Agency (3) Personal Data Authority (4) Personal Data Array

Last Answer : Personal Digital Assistant

Description : Suppose that we have numbers between 1 and 1000 in a binary search tree and want to search for the number 364. Which of the following sequences could not be the sequence of nodes examined? (A) 925, 221, 912, 245, 899, ... 926, 203, 912, 241, 913, 246, 364 (D) 3, 253, 402, 399, 331, 345, 398, 364 

Last Answer : (C) 926, 203, 912, 241, 913, 246, 364

Description : Suppose you have columns of data that span more than one printed page. How can you automatically print the column headings on each page? 1) Click Page Setup on the File menu, click the Sheet tab, ... Page Setup on the File menu, click the Sheet tab, and make a selection under the Print heading

Last Answer : 1) Click Page Setup on the File menu, click the Sheet tab, and enter the row that contains these column

Description : How much is 111 + 222?

Last Answer : 333

Description : What is 222 rounded to the nearest 10?

Last Answer : 220

Description : How many times does 37 go into 222?

Last Answer : Exactly 6 times

Description : What is the width of a rectangle who has 222 millimeters as the perimeter and a length of 60 millimeters?

Last Answer : ForP = perimeterL = lengthW = width2L + 2W = PFor the given information this means2x60 + 2W = 222120 + 2W = 2222W = 222W = 51So the Width would be 51 millimeters

Description : my blood sugar is 222 is that bad?

Last Answer : my blood sugar is 202 is that bad