Problem D. Euler Function

HDU - 6322