ybakun

Задача порівняння чисел

Jul 21st, 2021
561
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. // Задача порівняння чисел
  2. function numbersSum (a, b, c) {
  3.     if ((a + b + c) > 0 && (a + b + c) < 100) {
  4.         return 1;
  5.     } else if (a == b == c) {
  6.         return -1;
  7.     } else {
  8.         return Math.max(a, b, c);
  9.     }
  10. }
  11. console.log(numbersSum(90,5,2))
Advertisement
Add Comment
Please, Sign In to add comment