Raktim Posted February 11, 2019 Posted February 11, 2019 Sir, can I declare a Function with its return type and parameter's type on Python like C Language? void main() { void sum(int,int); /*function declaration*/ sum(5,5); } void sum(int x,int y)/*function defination*/ { /*function body*/ int result; result=x+y; printf ("The Sum is %d",result); } Can i do this same code on python? Python support Function Declaration? If yes, then how i declare a function on python
justsomeguy Posted February 11, 2019 Posted February 11, 2019 https://www.w3schools.com/python/python_functions.asp
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now