CJCoding With Joseph
15free / daySign inCreate account
Back to Code Walkthrough

Post-Increment as an Array Index

JavaScript code walkthrough · Question 25
mediumOperators

Code

Read carefully. What does this print?
1let i = 0;
2let arr = [10, 20, 30];
3console.log(arr[i++] + " " + arr[i++]);
4console.log(i);

Your answer