has same rightn most digit

 s

function hasSameRightmostDigit(num1, num2,num3) {
  // Get the rightmost digits of the two numbers.
  const rightmostDigit1 = num1 % 10;
  const rightmostDigit2 = num2 % 10;
    const rightmostDigit3 = num3 % 10;

  // Return true if the rightmost digits are the same, false otherwise.
  return rightmostDigit1 === rightmostDigit2 && rightmostDigit2 === rightmostDigit3;
}
console.log(hasSameRightmostDigit(12,22,22));
</script>

s

No comments:

Post a Comment

How to host application on server new way

 copy the htacess from public to root copy the server.php from public to root but rename to index.php htacess <IfModule mod_rewrite.c>...