[ 1/(X+ 12)+ 1/(X+27)]* X = 1
The solution is X= 18, so it takes 18+ 12=30 days for Party A to complete this work alone, and 18+27=45 days for Party B to complete this work alone.
Note: * indicates multiplication symbol.