Python Forum

Full Version: Python Function
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Write a program having a void function that receives a 4 - digit number and calculates the sum of square of the first two digits and last two digits .
Eg if 1233 is passed as argument then the function should calculate 12 square + 33 square
What is done with the result?
what have you tried? we are glad to help, but we are not going to do your homework for you. Show your code, full traceback (if you get any errors), ask specific questions.
Please, use proper tags when post code, traceback, output, etc.
See BBcode help for more info.
I tried it and it worked ! Thank you fro replying:)