December 24th, 2012, 08:34 AM
Reference with constant modifier
double &val = 66.6; //illegal
const double &val = 66.6; //legal
I was just doing some demo programs and came through the above concept but not able to identify what exactly the need of the above concept . what magic exactly const is doing in the second case ?
can anyone please let me know where exactly we can use this concept in real time programming ?
Tags for this Thread
Click Here to Expand Forum to Full Width
This a Codeguru.com survey!