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

sun dried potato procedure

  Sun-Dried Potato Chips Recipe  https://www.youtube.com/watch?v=e_PVvAU77Qs , recipe for potato sun dried chips 1) ist peel off the potato ...