Given an n*m chocolate bar, you need to break it into n*m 1*1 pieces. You can break a bar only in a straight line, and only one bar can be broken at a time. Design an algorithm that solves the problem with the minimum number of bar breaks.

Respuesta :

Answer:

See attached pictures.

Explanation:

See attached pictures for detailed explanation.

Ver imagen abdullahfarooqi
Ver imagen abdullahfarooqi
RELAXING NOICE
Relax