There is a vertical stack of books marked 1, 2 and 3 on Table-A, with 1 at the bottom and 3 on
the top. These are to be placed vertically on Table-B with 1 at the bottom and 2 on the top, by
making a series of moves from one table to another. During a move, the topmost book, or the
topmost two books, or all the three, can be moved from one of the tables to the other. If there
are any books on the other table, the stack being transferred should be placed on the top of the
existing books, without changing the order of the books in the stack that is being moved in that
move. If there are no books on the other table, the stack is simply placed on the other table
without disturbing the order of books in it. What is the minimum number of moves in which the
above task can be accomplished?