DEV Community

loading...

Discussion on: Daily Challenge #11 - Cubic Numbers

Collapse
wolverineks profile image
Kevin Sullivan
const isArmstrongNumber = (input: number) =>
  [153, 370, 371, 407].includes(input);

const display = (isArmstrongNumber: boolean) =>
  isArmstrongNumber ? undefined : "unlucky";