Well it's great.
File edition dot s h when we can break these functions on the first line start shoving
and we are going to do with all due the addition of two numbers.
So start with asking user for entering first number
now start the aspheric into variable first then ask for a second number.
And start the answer into variable.
Second.
Now we can call the function which will do addition of two enters numbers.
So my function will be called addition and it takes two arguments value or variable first and the value
of variable.
Second this function does not exist yet.
We need to create it but do remember under Tillery lecture we need to write declaration of a function
before the actual calling of that function.
So function addition and inside Gardley brackets I will write code Firstly let's assign into local variable
first first argument out of one and into local variable second assign second argument to why we are
creating local variables here.
We don't need that now.
But sometimes you want to change the value of arguments.
You don't want to change global variables and also we are using here are local variables as it is a
good example as you will see later.
Now let's do the actual audition using common blood.
So result is equal first class second
and we'll write the result to the screen.
Now just as an experiment increment the local variable first
and also increment a local variable.
Second now descript is dominant but we can ensure uphold our values of variables first and second so
we call
printing variables
and on the next line and other eco and print output of variable first and on the next line and other
Ikuko month and we'll print the screen value of variable.
Second
you can save this group Nahoum ground it could better missions
and you can get
for number 5 second number seven.
And the result is 12th grade.
It isn't working.
But he's not dead the variable first has the value 5 and the value of variable second is seven dead
means that the values of that variables are very changed even if we do incrementation in the function
because the increment and only local variables.
If I tried another numbers for example I can try number 10 and 20.
It is working also.
Bhaduri about some other numbers as what say mine was then.
And to it is working.
The result is minus eight grade but in function we are using a variable called result.
Is that a global variable.
Yes.
We didn't use keyword local the value of variable result is still the result of addition of two numbers
even though the function was finished.
So we in the script can still work with the value of variable result
even round described now.
And there are three and five.
We still see output of result even we use it at the end of the script.