Your indiscriminate use of "A", "B", and "a", "b" makes this a little hard to read! I am going to stick with "A" and "B". Since A would take 60 days to do the job alone, he works at the rate of 1/60 "job per day". Since B would take 75 days to do the job alone, he works at the rate of 1/75 "job per day". Working together they work at the rate of 1/60+ 1/75= 1/(12*5)+ 1/(25*5)= 25/300+ 12/300= 37/300.
Let "x" be the number of days they work together. The accomplish 37x/300 of the job which leaves (300- 37x)/300 still to be done. B, doing that alone, will take ((300- 37x)/300)(75)= (300- 37x)/4= 30.