Javascript - Write program to calculate a remainder of 10 / 3.

Requirements

Use the %= operator to assign a remainder of 10 / 3 to the variable x.

var x = 10;
// add code here
console.log( x );

Demo

var x = 10;
x %= 3;
console.log( x );

Result

Related Exercise