Skip to content

Instantly share code, notes, and snippets.

@yashasvi9199
Created July 13, 2023 13:23
Show Gist options
  • Save yashasvi9199/27212e5bfad534abbf511d7be1c38916 to your computer and use it in GitHub Desktop.
Save yashasvi9199/27212e5bfad534abbf511d7be1c38916 to your computer and use it in GitHub Desktop.
<html>
<head>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.6.4/jquery.min.js"></script>
</head>
<script>
$(document).ready(function() {
var input = [];
for (var i = 0; i < 2; i++) {
if (i == 0) input[i] = prompt("Please enter dividend Number");
if (i == 1) input[i] = prompt("Please enter divisor Number");
}
var mod = input[0] % input[1];
alert("The remainder after deviding " + input[0] + " with " + input[1] + " is " + mod);
})
</script>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment