+ 4

How to define a function in python programming.

Define a function in python programming

30th Mar 2021, 1:32 PM
Sutharsan
Sutharsan - avatar
6 odpowiedzi
+ 4
def anurag: print("hello") def =>define function after 😊 anurag=>function name 😊 :=>Most important 😊 print("hello")=>written statement for functions and indentation is most important 😊 if you will not give then it will give you a indentation error This is simple function for python if you want more advanced than go and take sololearn PYTHON core course and start learning Sutharsan.S
30th Mar 2021, 2:34 PM
Anurag Kumar
Anurag Kumar - avatar
30th Mar 2021, 2:23 PM
Scarlet Witch
Scarlet Witch - avatar
+ 6
def
30th Mar 2021, 1:36 PM
Илья Мирошник
Илья Мирошник - avatar
+ 4
If you followed the python tutorials here, you would know.
31st Mar 2021, 9:55 AM
Sonic
Sonic - avatar
+ 1
def square(x): print(x*x) square(2) #function is called square is the name of the function def is the keyword x is the argument that is to be passed in the function.
31st Mar 2021, 6:53 AM
BIDISHA CHAKRABORTY
BIDISHA CHAKRABORTY - avatar
0
Sutharsan.S You can define a function using def. for more information you need to learn python.
1st Apr 2021, 1:11 AM
❤️😍Prerana😍❤️
❤️😍Prerana😍❤️ - avatar