New answers tagged

0 votes

Binary representation of a number is palindrome or not?

Thunno 2, 12 bytes ḃḲQ"YESNO"½i Attempt This Online! Unfortunately, the Thunno 2 dictionary only holds words which are 4 letters or more, so neither <...
The Thonnu's user avatar
  • 11.4k
0 votes

Binary representation of a number is palindrome or not?

Python, 84 Bytes f=lambda x:['NO','YES'][int(bin(x)[2:]==(bin(x)[2:])[-1::-1])] print(f(int(input()))) Try online on TIO If just a pure function was allowed: Try ...
Hippopotomonstrosesquipedalian's user avatar
2 votes

Binary representation of a number is palindrome or not?

Arturo, 47 bytes print(=reverse<=as.binary do arg\0)?->'YES->'NO
chunes's user avatar
  • 18.1k
2 votes

Binary representation of a number is palindrome or not?

JavaScript, 75 bytes 69 bytes alert((a=[...(+prompt()).toString(2)]).some(x=>x-a.pop())?"NO":"YES") Try it online! A different approach ...
nascente_diskreta's user avatar
1 vote

Binary representation of a number is palindrome or not?

Japt, 13 bytes ¢è¬?`y`u:"NO Try it
Shaggy's user avatar
  • 40.5k
1 vote

Binary representation of a number is palindrome or not?

Nibbles, 11.5 11 bytes (22 nibbles) Edit: -1 nibble thanks to xigoi ?==;``@$\@"YES" "NO" ...
Dominic van Essen's user avatar
4 votes

Binary representation of a number is palindrome or not?

Vyxal, 85 bitsv1, 10.625 bytes -6 bits thanks to @lyxal -3 bits thanks to @the-thonnu bḂ≠`∨ȯno`½iN Try it Online! ...
emirps's user avatar
  • 1,666
0 votes

User Appreciation Challenge #1: Dennis ♦

Python 3, 65 bytes lambda s:(l:=[c in'aeiou'for c in s.lower()if'`'<c<'{'])==l[::-1] Try it online!
c--'s user avatar
  • 1,469
1 vote

User Appreciation Challenge #1: Dennis ♦

Thunno 2, 4 bytes ỊṃḲ⁼ Explanation ...
The Thonnu's user avatar
  • 11.4k
1 vote

User Appreciation Challenge #1: Dennis ♦

Scala 3, 78 bytes Golfed version. Attempt it online! _.filter(_.isLetter).map(c=>"aeiou".contains(c.toLower)).pipe(c=>c==c.reverse) Ungolfed ...
138 Aspen's user avatar
  • 2,001
1 vote

User Appreciation Challenge #1: Dennis ♦

Arturo, 58 bytes $=>[=reverse<=map replace&{/\p{^L}}""=>[in?&"aeiouAEIOU"]] Try it
chunes's user avatar
  • 18.1k

Top 50 recent answers are included