Can you hack this? #2

Write an isEven function to check if a number is even without using the modulus operator.

const isEven = (n) => …

isEven(2) // => true
isEven(‘127′) // => false
isEven(’12abc2’) // => false


This content originally appeared on DEV Community and was authored by Alfredo Salzillo ?

Write an isEven function to check if a number is even without using the modulus operator.

const isEven = (n) => ...

isEven(2) // => true 
isEven('127') // => false
isEven('12abc2') // => false 


This content originally appeared on DEV Community and was authored by Alfredo Salzillo ?


Print Share Comment Cite Upload Translate Updates
APA

Alfredo Salzillo ? | Sciencx (2021-04-25T10:02:21+00:00) Can you hack this? #2. Retrieved from https://www.scien.cx/2021/04/25/can-you-hack-this-2/

MLA
" » Can you hack this? #2." Alfredo Salzillo ? | Sciencx - Sunday April 25, 2021, https://www.scien.cx/2021/04/25/can-you-hack-this-2/
HARVARD
Alfredo Salzillo ? | Sciencx Sunday April 25, 2021 » Can you hack this? #2., viewed ,<https://www.scien.cx/2021/04/25/can-you-hack-this-2/>
VANCOUVER
Alfredo Salzillo ? | Sciencx - » Can you hack this? #2. [Internet]. [Accessed ]. Available from: https://www.scien.cx/2021/04/25/can-you-hack-this-2/
CHICAGO
" » Can you hack this? #2." Alfredo Salzillo ? | Sciencx - Accessed . https://www.scien.cx/2021/04/25/can-you-hack-this-2/
IEEE
" » Can you hack this? #2." Alfredo Salzillo ? | Sciencx [Online]. Available: https://www.scien.cx/2021/04/25/can-you-hack-this-2/. [Accessed: ]
rf:citation
» Can you hack this? #2 | Alfredo Salzillo ? | Sciencx | https://www.scien.cx/2021/04/25/can-you-hack-this-2/ |

Please log in to upload a file.




There are no updates yet.
Click the Upload button above to add an update.

You must be logged in to translate posts. Please log in or register.