A,s 1 days work =1/8
B's 1 day's work in breaking the building = 1/3
Now, according to the question,
A's 4 day's work = 4 x (1/8) = 1/2
Now, A's and B's 2 day's work
= 2[(1/8) - (1/3)] = 2 x (-5/24) = -10/24
Total work done in 6 days = 1/2 + (-10/24) = (12 - 10)/24 = 2/24 = 1/12
Remaining work = 1 - (1/12) = 11/12
Now, A has complete the work, so A can complete in N days.
(1/8) x N = 11/12
⇒ N = (11 x 8) / 12
N = (11 x 2)/3 = 71/3 days