Hey, guys, what's up?
So today we are swallowing one when dusting problem so that proneness treatment is given the most given
numbers.
Slap them.
For example, let's say doing a massage is five and B's seven.
So by stripping, I mean, is the new video fair is seven and B is five.
OK, so the venues of A&E are slapped with each other.
So how against all this problem?
So what we can use is, first of all, we were doing the most and and B, we will take input from the
user.
What other do they lose?
OK.
Then what do we do?
We will take one temporary variable and dump families.
Atambayev anyway.
And it will store live in the OWFI.
So let's see, is five and B is seven.
So I am what I am doing.
I am making a temporary variable and this temporary variable will also hold the five.
I cooperate disvalue here.
OK, then what I will do, I will right.
It was be so cooperative and will be in to it.
So here it will become seven.
OK, we have to copy the value.
So the new video fee is seven.
Then what do we do.
We will write be it was temp.
So what is the new value of B new value.
B is five and Dukan.
And finally, you can see yourself the new radio phase seven and the new valve BS five.
So the numbers are slabbed.
Initially it was five and B was seven.
OK.
So with the help of these three lines, I can slap two numbers.
OK.
Let's take one more example.
Suppose the value of is to add the value of Beastie so badly off a stool, then lay off.
B is T.
Now what I'm doing.
I am creating a temporary variable.
So this is my time.
Very valuable.
And this is holding the value of a.
This is basically copy the value of a temp.
Copy the value of it.
And don't temp.
So too is here.
Now that we are doing copy the value of B in to it.
So copy the value of be in to A.
So then you and your phase three.
Now what our doing.
Copy the value of temp in to be complementary of temp.
And to be so new.
Any of these two.
So finally it becomes T and B becomes two.
So then the Mozart swept.
OK.
So let's try it called.
Let's name it.
So Abdool numbers.
NBPA.
So what do we have to do?
OK, so first of all, what do we do?
We will take Goonan marriage and but.
So let's say I do it on my side, A and B, let us take input from the user.
So first of all, let us sprint the car into a low fare and we'll see you out before slapping.
So before slapping the value of A and B are so C out it was.
And similarly, Soucy out a push, a
hard line and see out.
We put.
So this is the case before swapping.
Now they will swap for swapping, but they do.
We will take a very, very temp, which is initially a copy of a new offering to be then.
But I will do I will copy the value of B into A.
And then copies of any of them.
And to be OK.
Now let us print these values again.
After swapping.
So after slapping.
Now, this is all that we have to do to solve this problem.
So let us test our program.
So let's say the value of A and B are five and seven.
So before setting the radio phase five, after snapping the value of a seven, before stepping the value
of these life, after setting the value of these SODI, before setting the value will be seven.
And after us, I think it becomes five.
OK.
So the values are getting swept.
Nowadays, one more way in which we can do a swapping, and that is with the help of Zord, Rick Lazio,
Peter Zord.
OK, so what we will do.
I suppose the value of is five and the value of these seven.
I will write a quiz is ought to be OK.
So a quiz.
The current value of phase five and these seven.
So this is the new video feed.
Then I will write be equals is or be.
So be it was.
What is the value of the value of phase five or seven.
Then take Zschau Revd B and R this B seven.
So seven.
Now seven a.m. and I will cancel out each other BS.
Five gained right.
Equals A zone B so a quiz.
What is the value of the value of eight five zero seven.
So five is on seven.
Then I have to take Zah would be.
And what is B B's five.
So five.
Five and five.
But against each other.
The new yellowface.
Seven.
So you can see here the value of B is now five.
So value of B is five and the value of A is now seven.
So the value of it is now seven.
So values are getting slammed.
OK.
So the values are getting swept.
So let's come and out.
So what we can do is a quiz.
Is order B B GWAS is odd is or B and again eight was A czar B.
OK,
let's say the value of and B are five and seven.
So you can see the values out of getting slammed.
Initially it was safe.
Now is seven.
Initially B was seven.
After I bring it becomes five.
So the vendors are getting stabbed.
Led to the radio phase one and the value of bees, too.
So, again, the values are getting swept.
OK.
Now what C++ does, this trapping operation is very common.
We have an inverted function to slap two numbers.
The function is slap a call maybe.
No.
Now the values of A and B will be slabbed.
OK, so this is an N word function slap.
Let's say a five and B's seven.
So the values are getting slapped.
Five, seven.
OK, one more time.
Answer the value of a one and these two.
So they may lose out of getting seven.
OK, so this.
So where did the team method first with the help of M variable.
Second with the help of bitwise operator tzar.
And third, we have in both function to heping.
So I will always use this.
You can use annual Dubeau to or you can also use this material.
Always use this sarap a comma B.
OK.
So this is all for this video.
Thank you.