hi hello welcome to my blog so now we are going to see what are functions?
Function is a piece of code is executed when you call that function.
so why we need Function?
a repeated piece of code which is written multiple times instead of that when we write that code inside a function we don't have to write repeated piece of code. simply we can call that function for repeated task with different arguments to produce different results.
definition of function?
Function with parameters
Function with Return
when we call a function it will perform some operation and return some result to the caller using return keyword
How to call Function?
we can call the function by function name( )
Passing values to the function and getting output