Javascript - Write program to Find the remainder when 15 is divided by 9, using two variables x and y.

Requirements

Write program to Find the remainder when 15 is divided by 9, using two variables x and y.

Hint

You can define the two variables as

var x;
var y;

Use the modulus operator (%).

Demo

var x = 15;
var y = 9;
console.log( x % y );

Result

Related Exercise