Here students will read CS502 Solved MCQs for midterm so students if you are looking for CS502 Midterm, Solved MCQs but you could not find it anywhere here we always help our students by providing them free study solutions. Students this is the CS502 - Fundamentals of Algorithms MCQs for midterm only and we will try to upload them soon for final term exams. Fundamentals of Algorithms is a computer book as well students will read about algorithms in this book. Many students like to read and implement code in computer science books but some naughty students who don't interest in coding and books so they feel bad to read any book and spend some time reading the lesson. But students to read books because nowadays we can learn anything but before paper, we could prepare their exams easily. Students you can share  with more students who are interesting in this book and they want to read these

We Also Recommend


CS502 - Fundamentals of Algorithms MCQs


Post TitleCS502 Solved MCQs Midterm
Book CodeCS502
DegreeBSIT/BSCS/Other
UniversityVirtual Univerity of Pakistan
CS502 MCQsCS502 Solved MCQs
Mid/FinalCS502 Solved MCQs Midterm
Also, ReadCS502 Midterm MCQs
Also, ReadCS502 Quiz 1 Solution


CS502 Solved MCQs Midterm



The approach of solving geometric problems by sweeping a line across the plane is called……………..(CS502)


Box 

Line 

Plane 

Cube 


The sleeve technique is a special case, where the number of subproblems is just ……………(CS502)


4

2

3

1


The brute force algorithm for 20 maxima is operated by comparing ………….pairs of points.  (CS502)


Some 

Two

Most 

All


…………is not a characteristic of a random-access machine.  (CS502)

 

Locality of reference 

Executing an arithmetic instruction 

Assigning a value to a variable 

Single processor 


The efficient algorithm requires less computational ……………(CS502)


Memory and running time 

Notation 

Running time 

Memory


In the following code the statement cout <<i, executes …………….for (int i=1, i< = n,i++) cout <<i;  (CS502)


N+5 times 

Infinite times 

N times zero times 

If we associate (x,y) integers pair to cars where x is the speed of the car and y is the negation of the price. High value for a car means a ……………car.  (CS502)


Cheap 

Expensive 

Slow

Fast 


…………….time is the maximum running time overall legal inputs.  (CS502)


Good case 

Average case

Worst case 

Best case 


The brute force algorithm for 2D maxima runs in order O (.....) time.  (CS502)


n(log n)

N

N”n

N3


The omega notation allows us to state only the asymptotic …….bounds.  (CS502)


Upper

Middle

Lower

Both lower & upper


While applying the sleeve techniques to selection sort, how to choose a pivot element.  (CS502)


Linear 

Randomly

Sequentially

Through mean 


To predict the cost of an algorithm in terms of resources is called…………..(CS502)


Design 

Output

Key

Analysis


Plane sweep uses …………….for staring maximal points.  (CS502)


Stack 

Array 

Queue 

List 


In order to say anything meaningful about our algorithm, it will be important for us to settle on a ………….(CS502)


Mathematical model of computation 

Pseudo program 

C++ program 

Java program 

For 2D maxima problem, plane sweep algorithm first of all ………….(CS502)


Delete some points 

Output the elements 

Pushes all points on the stack 

Sort all points 


8n2+2n -3 will eventually exceed c2(n) no matter how large we make………..(CS502)


2n

This equation 

N

c2 


In the following code the statement cout <<j, executes …………..times. For (j=1,j<=5,j=j+2) cout <<j.  (CS502)


2 times 

5 times 

3 times 

0 times 


If we have an equation 8n2+7f+6 then n is large,...........term will be much larger than the n term and will dominate the running time.  (CS502)


n^2

f(n)

g(n)^2

f[g(n)


Asymptotic growth of plane sweep algorithm for 2D maxima problems is ………….(CS502)


e(n)

e(nlogn)

e(logn)

e(n^2)


Applying the sleeve technique to the selection problem………. the element is picked from the array.  (CS502)


Output 

Total 

Pivot

Input


Plane sweep uses ……….for storing maximal points.  (CS502)


Stack 

Queue

Array 

List 


In-plane sweep approach,a vertical line is swept across the 2d plane and …………structure is used for holding the maximal points lying to the left of the sweep line.  (CS502)


Tree

Stack 

Array 

Queue 


In running time analysis we are also concerned about the ………required by the algorithm.  (CS502)


Memory 

Both space and memory 

Space 

Code


Which of the following is calculated with Big O notation?  (CS502)


Lower bounds 

Both upper and lower bounds 

Upper bounds 

Medium bounds 


In the merge sort algorithm, we split the array …………….to find index q.  (CS502)


From start 

Both from start or end 

Midway 

From end 

For solving the selection problem we introduced the sleeve technique due to ……….(CS502)


Eliminating the rank of an element 

Using a decrease and conquer strategy 

Avoiding sorting all input data 

Using brute force approach 





If we associate (x,y) integers pair to cars where x is the speed of the car and y is the negation of the price. High y value for a car means a …………..car.  (CS502)


Expensive 

Fast 

Slow 

Cheap 


CS502 Solved MCQs Midterm

CS502 Solved MCQs Midterm

Post a Comment

Powered by Blogger.