If __name__=='__main__'

# u can import this whole by import its file name

def printhar(string):
return f"ye string harish ko de de {string}"

def add(num1, num2):
return num1 + num2 + 5
print("u came from", __name__)

if __name__ == '__main__': # this will not execute below given syntax

print(printhar("takur"))
print(add(5, 5))

Comments

Popular posts from this blog

Steps taken by a compiler to execute a C program

Tokens in C

Variables and Data Types in C