+ 2

what happens to the previously assigned index value? (check description)

int b[]={12,14,45,34}; b[0]=10; what happens to the previous value of b[0]?

2nd Nov 2016, 2:12 PM
Ashwin Manoj
4 Antworten
0
is replaced the value 12 disappears.
2nd Nov 2016, 2:18 PM
Badila Timotei
Badila Timotei - avatar
0
thanks!
2nd Nov 2016, 2:26 PM
Ashwin Manoj
0
It is replaced by 10.
2nd Nov 2016, 2:29 PM
Harry Pearson
Harry Pearson - avatar
0
12 is replaced by 10. Youre basically assigning b[0] a new value. Thats why we call "=" an assignment operator.
2nd Nov 2016, 3:11 PM
Jonah Berry
Jonah Berry - avatar