00:01
Okay, so in this question we want to write a function named display value that will return nothing and accept one parameter as an integer and display the value of that integer.
00:16
So here i have my basic c+ + program, my hello world program.
00:24
And if i run it, as you can see, it outputs hello world.
00:28
And so we know everything compiled well and we're going to start programming our function we're going to program our function above the main as the compiler remember it reads from the first line to the last line so we need to declare our functions before we use them and we're going to use our function in the main later on we're going to declare it first first, what's the return type of the function? because a c+ + function should have the return time first.
01:06
Well, it says that it returns nothing.
01:10
So in c++, you return nothing, you need a function that's void.
01:15
And what's the name of the function? the name of the function is display value.
01:23
Now we have the name of the function.
01:25
And what does it take as a type of input? it takes an integer, and we're going to give it a name.
01:38
We're going to give it value to display.
01:45
This is the function.
01:53
And what do we want this function to do? well, we simply want the function to output on screen what the value is.
02:03
So as you can see from my hello world program, you can simply use a standard function c out to output things on screen.
02:13
I'm going to write this here, std, c out...