Home »
MCQs »
JavaScript MCQs
Does JavaScript support increment (++) and decrements (--) Operators?
33. Does JavaScript support increment (++) and decrements (--) Operators?
- Yes
- No
Answer: A) Yes
Explanation:
Yes, JavaScript supports increment (++) and decrements (--) operators.
Example:
<script>
var x = 5;
document.getElementById("test").innerHTML = ++x;
</script>