A can do a piece of work in 18 days. B in 27 days and C in 36 days.
A can do a piece of work in 18 days. B in 27 days and C in 36 days. They start working together but only C works till the completion. A leaves 7 days and B leaves 8 days before the completion of work. The whole work was completed in