+ 2
Change const value CPP
I cannot understand this peace of code, here I'm changing the value of a const!! Do I have 2 constant var with the same name? https://code.sololearn.com/c8zy5vrL3VQ6/?ref=app
9 Answers
+ 4
@immortal, thank you đ
+ 3
So can I consider them as 2 different variables?
+ 3
@Deepak, I did this just before posting the question, they have different addresses
0
You do not change constant value, you just create new costant in given scope.
0
thanku immortal