If it takes X days for A to do a project alone, then his efficiency is1/X.
Cooperation time: if it takes X days for Party A to do a project alone and Y days for Party B to do a project alone, the cooperation can be completed in one day.
The equation is: (1/x+1/y) * a =1.
Take the total amount as the unit "1", and then according to the topic, see how Party A, Party B, Party C and Party D completed this project and how many days it took. Finally, the sum of everyone's efficiency multiplied by the number of days is unit one.
It takes y days to set b separately.
Efficiency of a: 1/40 B:1/y.
( 1/40+ 1/y)20+20 * 1/y = 1
The answer is y=80.