Step by step solution