python code 12

Complete the content as required. Please use Python IDLE.

Please post the input and output pictures and send me the source code. Thank you!