Please Comment, Subscribe and Click Bell🔔🔔🔔 Icon for More Updates. To learn software course from our experts please register here for online training: goo.gl/HIB0wL
sir like your explanation nothing great i from the deep of heart thankyou for your free and much much valued explanation. sir you are unknowingly helping lot of students .lord will give you a great gift for this #noowords#salutetokishoresir
I have seen that in place of return type as void, which you have used, some people use return type as istream& and ostream& and then return in and out respectively in the end of overloading functions. How is that different?
When we are using cin>>obj1>>obj2>>obj3; Then we must return with&. because obj1 get scanned with cin but for obj2 to get scan with cin it is needed to return
@@creative_rvish the difference is simple, let us say there is a add function which add two numbers, it is like printing sum of two numbers within that add function (in case of void return) or returning the sum to an outside variable and printing it(in case of int/float return).......so with void we print the objects in operator function itself and with returning we return the stream of objects and print outside
@Naresh i Technologies Hello Mr. Kishore, I can I ask why you have declared and defined the friend function inside the class this time around? Also why have you used &in, &out and &stu in your functions this time but not before? what is the rule/ theory behind using ampersand?
Because for istream and ostream class there is no this pointer implicitly so it is not work without reference type. If you want to see this go to shallow copy and deep concepts then u able to know
adarsh verma there is no need to do that. You can, I suppose, but that simply allocated more memory for an object that has been predefined. All you need to do is send the cout object and use a reference to access the functionality of it.
Please Comment, Subscribe and Click Bell🔔🔔🔔 Icon for More Updates. To learn software course from our experts please register here for online training: goo.gl/HIB0wL
Thank you so much sir, aap ne ek baar mai samjha dia, i was struggling from 2 days for the same concept.
Thank you very much. You are better than my oops&ds lecturer ❤️
this is the best video about this topic in entire the whole internet !!!
From PAKISTAN u explained very well sir
Sir
Continue the videos.
Videos are so clear and the crystal clarity
Finally ,i understood insertion and extraction operator in cpp,thanx sir.
your class is ozm am really liking it
Thankyou sir finally I got it
Thanks for clearing my concept!!
Thank you sir for the awesome video
Thank you sir! you explain it so clearly!!!!
Very helpful video highly recommended 🤩🤩🤩
Thanks a lot sir ☺️☺️
Thank you for this video, it was very helpful!
You are Amazing Sir
Thanks for such a good lecture
sir like your explanation nothing great i from the deep of heart thankyou for your free and much much valued explanation. sir you are unknowingly helping lot of students .lord will give you a great gift for this #noowords#salutetokishoresir
Good explanation
Thank you sir.....🙏🙏🙏
Very helping video keep it up
I have seen that in place of return type as void, which you have used, some people use return type as istream& and ostream& and then return in and out respectively in the end of overloading functions. How is that different?
Rohan Kimothi same doubt
I have also this same doubt so please sir reply as soon as possible
When we are using cin>>obj1>>obj2>>obj3;
Then we must return with&. because obj1 get scanned with cin but for obj2 to get scan with cin it is needed to return
@@creative_rvish the difference is simple, let us say there is a add function which add two numbers, it is like printing sum of two numbers within that add function (in case of void return) or returning the sum to an outside variable and printing it(in case of int/float return).......so with void we print the objects in operator function itself and with returning we return the stream of objects and print outside
because of >> operator is belongs to istream and > and
tqsm sir🙏🙏
thank you
exelent video thanks siir
@Naresh i Technologies
Hello Mr. Kishore,
I can I ask why you have declared and defined the friend function inside the class this time around?
Also why have you used &in, &out and &stu in your functions this time but not before? what is the rule/ theory behind using ampersand?
Because for istream and ostream class there is no this pointer implicitly so it is not work without reference type. If you want to see this go to shallow copy and deep concepts then u able to know
@@smarttube1141 but what about stu?? Why we are using reference type there?
Very nice
Nice sir
kaiya gam no he tu
Thank U sir
add function overloading sessions
How can we overload like:
Cin››a››b;
Where a and b are objects of particular same class
to achieve this cin>>a>>b your operator overloading function should return cin and return type must be istream&
can we perform this program without using reference variable means can we make normal objects of istream and ostream
adarsh verma there is no need to do that. You can, I suppose, but that simply allocated more memory for an object that has been predefined. All you need to do is send the cout object and use a reference to access the functionality of it.
The main purpose of using reference is to minimise memory
does the header file contain .h
?
How are you using without returning the objects in and out ?
here we are reading the data from in and showing the data by out.....
For binary operator overload one implicit one explicit na
You are saying both expliciy
You are saying both explivit
@@rejetimeghavardhan7805 both explict
can we define friend fun inside the class?
No we can't define inside the class. friend function is declared inside the class and defined outside the class always.
yes in case of operator overloading it can be inside or outside of the class....
@@amitkumargupta6722 No! U r incorrect!
@@ashutoshsingh7713 he is correct , in case of operator overloading we can define friend function inside or outside the class
@@sharath5796 ohhh nice info thanks yar :) new to me.
This program gives error! Friend operator can't be defined inside the class
English bolna zarori hai hai kya????
Good Explain Sir
Thank you sir🙏🙏
Thanks Sir
Thankyou sir
Thank you sir