TypeScript
TypeScriptMister-Hope
Mister-Hope
/*
* Your runtime beats 100 % of typescript submissions
*
* Your memory usage beats 88.89 % of typescript submissions (38.8 MB)
*/
const canWinNim = (n: number): boolean => n % 4 !== 0;
simple
/*
* Your runtime beats 100 % of typescript submissions
*
* Your memory usage beats 88.89 % of typescript submissions (38.8 MB)
*/
const canWinNim = (n: number): boolean => Boolean(n % 4);