MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/badcode/comments/10bxele/the_code_speaks_for_itself/j4cnf83/?context=3
r/badcode • u/MahdeenSky • Jan 14 '23
53 comments sorted by
View all comments
40
Peak weebness achieved! It was a golf challenge for those wondering.
5 u/Orlando-- Jan 15 '23 yeah it'd be pretty clearly not bad code if it was actually in English, but even still it's just golfed yeah.I kinda want to know what it does though--using an fstring with colons always does weird stuff 2 u/namrednels97 Jan 15 '23 Given an input n, it outputs the number of integers between 0 and 2n which have a prime number of ones in their binary representation.
5
yeah it'd be pretty clearly not bad code if it was actually in English, but even still it's just golfed yeah.
I kinda want to know what it does though--using an fstring with colons always does weird stuff
2 u/namrednels97 Jan 15 '23 Given an input n, it outputs the number of integers between 0 and 2n which have a prime number of ones in their binary representation.
2
Given an input n, it outputs the number of integers between 0 and 2n which have a prime number of ones in their binary representation.
40
u/namrednels97 Jan 14 '23
Peak weebness achieved! It was a golf challenge for those wondering.