When we have const or references in assignment operator , then compiler force you to write your own assignement operators. The reason is , const and reference variables can not be re-assigned once we initialized them during construction.
Thursday, 3 April 2014
When you HAVE TO write assignment operator?
Labels:
assignment operator,
c++,
mandatory
Subscribe to:
Post Comments (Atom)
AWS Data Pipeline Services
https://www.youtube.com/watch?v=tykcCf-Zz1M
-
Given n numbers, find out i and j where 1<=i<=j<=n, where the sumof elements from i to j is maximum. All positive : Sum of all ele...
-
STL Benifits: 1.Code Reuse 2.Efficiancy and Fast 3.Accurate and less buggy 4.Simple code and readable 5.Standardized and helps in writ...
-
Breadth First Algorithm OR Level wise printing of a BST: /* Breadth first traversal using queue */ void BreadthFirstTraversal(Tree *root)...
No comments:
Post a Comment