Cats and a Mouse
Solution in Javascript const x = 1; const y = 2; const z = 3; function catAndMouse(x, y, z) { const A = Math.abs(z-x); const B = Math.abs(z-y); if (A B){ console.log('Cat B'); }else if (A === B){ console.log('Mouse C'); } } catAndMouse(x, y, z); Reference www.hackerrank.com/challenges/cats-and-a-mouse/problem
Algorithms
2020. 9. 17. 20:14
공지사항
최근에 올라온 글
최근에 달린 댓글
- Total
- Today
- Yesterday
링크
TAG
- hackerrank javascript solution
- compareTo()
- 프로그래머스
- equals()
- java
- easy javascript algorithm
- Collection Framework
- 알고리즘
- math.max
- ... in Javascript
- math.abs
- javascript
- Object type casting
- 프로그래머스 알고리즘
- code refactoring
- substring()
- HashMap
- C++
- hackerrank javascript
- Javascript Algorithm
- hackerrank solution
- 프로그래머스 알고리즘문제
- HackerRank Algorithm
- string class in java
- hackerrank
- spring boot application
- easy algorithm
- rest parameter
- algorithm
- repeat()
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | ||
6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 |
20 | 21 | 22 | 23 | 24 | 25 | 26 |
27 | 28 | 29 | 30 |
글 보관함