The Gateway to Computer Science Excellence
+3 votes
129 views

In Tower of Hanoi  problem if the condition that  A larger disk can not be kept on a smaller disk is removed, then the number of moves required to move $n$ disks

  1. $2n - n$
  2. $2n - 2n$
  3. $2n - n2$
  4. $2n - 1$
in Programming by Veteran (75k points)
edited by | 129 views
0

Bikram sir please correct it that answer is D) and no of moves required is 2n -1 by mistakenly it was written 2n-1.

ref :- https://en.wikipedia.org/wiki/Tower_of_Hanoi

0

Shubhanshu 

2n -1 is correct .

 with restriction it is  2n - 1  

 without restriction it is 2n-1

see this line " A larger disk can not be kept on a smaller disk is removed " ..

0
Thanks @Bikram Sir,

1 Answer

+3 votes
Best answer

All the options are incorrect , and it seems like Option D is misprinted that is instead of 2n-1, they have printed 2n - 1.

The correct answer should be 2n-1, because since  the restriction has been removed (that is we can place big disk over small disk) the number of  disk movement will be reduced.

No of Disk     No. of movements   

3                    7(with restriction) i.e 2n - 1

                      5 (without restriction) i.e 2n-1

--------------------------------------------------

4                    15(with restriction)

                      7(without restriction)

Update: Options have now been corrected.

by Active (2.4k points)
edited by
0
Please explain in more detail
0

The original Tower of Hanoi problem has an condition/restriction that big disk can't be placed over small disk. So, the no of disk movement will be more,2n-1 disk movements exactly.

But in this question, they have asked to calculate disk movement in tower of hanoi problem without the above mentioned condition/restriction. 

So the answer for this 2n-1 disk movements.

Answer:

Related questions

Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true
50,737 questions
57,406 answers
198,629 comments
105,468 users