The correct option is A Sound will be louder but the pitch will be the same.
When the mechanical piano is struck harder the second time, the sound will be louder but pitch remains the same because the frequency has not changed. The pitch depends on the frequency of the particular key which is being hit and hence there would be no change in the pitch of the sound.
Loudness depends on the square of the amplitude of the wave. Amplitude is the size of the vibration, and this determines how loud the sound is. Larger vibrations make a louder sound. Pitch of the sound depends on the frequency of the wave, which does not change when the key is struck harder.