HackerRank Backtracking Quiz-1

Question 1

Time: 00:00:00
Which among the following is true about Backtracking?

i: is a technique based on an algorithm to solve the problem

ii: uses recursive calling to find the solution

iii: emoves the solutions that don’t give rise to the solution

iv: problem-based on the constraints

 

i and ii

i and ii

ii,iii,iv

ii,iii,iv

 i and iii

 i and iii

All the above

All the above

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Question 2

Time: 00:00:00
Some of the challenges the backtracking can tackle are: 

 

Sorting the array of integers in a {1:n}

Sorting the array of integers in a {1:n}

n - Queens problem

n - Queens problem

Sum of subsets problem

Sum of subsets problem

All the above

All the above

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Question 3

Time: 00:00:00
In which of the following problems we make use of backtracking algorithms

n - Queens problem

n - Queens problem

Sum of subsets problem

Sum of subsets problem

hamiltonian circuit problem

hamiltonian circuit problem

All of the above

All of the above

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Question 4

Time: 00:00:00
Which appears when a complete solution arrives at the backtracking algorithm?

Recursively traverses through the same route

Recursively traverses through the same route

 continues searching for other possible solutions

 continues searching for other possible solutions

backtracks to the root

backtracks to the root

All the above

All the above

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Question 5

Time: 00:00:00
We use state-space trees for implementing

Backtracking

Backtracking

Mapping

Mapping

 Recursion

 Recursion

none of the above

none of the above

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Question 6

Time: 00:00:00
Which of the following does provide an optimal solution to the problem of 8-queens?  

(6,2,7,1,4,8,5,3) 

(6,2,7,1,4,8,5,3) 

 (4,1,5,8,6,3,7,2) 

 (4,1,5,8,6,3,7,2) 

(5,3,8,4,7,1,6,2) 

(5,3,8,4,7,1,6,2) 

All the above

All the above

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Question 7

Time: 00:00:00
How so many possible solutions to an 8-queen problem are available?

99

99

92

92

93

93

90

90

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Question 8

Time: 00:00:00
If we are coding for a algorithm where time is an essential parameter, which is the best techniques that we should use

Backtracking

Backtracking

Brute force

Brute force

Hit and trial

Hit and trial

None of the above

None of the above

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Question 9

Time: 00:00:00
Which of the following algorithms is used for constructing a state space tree ?  (AVAILABLE)

DFS

DFS

BFS

BFS

Nearest neighbor first

Nearest neighbor first

All the above

All the above

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Question 10

Time: 00:00:00
Which of the following is true about promising nodes?  

(AVAILABLE)

It is a node with most number of childs

It is a node with most number of childs

 It is the node which can lead to a complete answer

 It is the node which can lead to a complete answer

all the child nodes are called promising nodes

all the child nodes are called promising nodes

none of the above

none of the above

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

["0","40","60","80","100"]
["Need more practice!","Keep trying!","Not bad!","Good work!","Perfect!"]

Personalized Analytics only Availble for Logged in users

Analytics below shows your performance in various Mocks on PrepInsta

Your average Analytics for this Quiz

Rank

-

Percentile

0%

Get over 200+ Courses under One Subscription

mute

Don’t settle Learn from the Best with PrepInsta Prime Subscription

Learn from Top 1%

One Subscription, For Everything

The new cool way of learning and upskilling -

Limitless Learning

One Subscription access everything

Job Assistance

Get Access to PrepInsta Prime

Top Faculty

from FAANG/IITs/TOP MNC's

Get over 200+ course One Subscription

Courses like AI/ML, Cloud Computing, Ethical Hacking, C, C++, Java, Python, DSA (All Languages), Competitive Coding (All Languages), TCS, Infosys, Wipro, Amazon, DBMS, SQL and others.