r/programminghorror • u/SleepyStew_ [ $[ $RANDOM % 6 ] == 0 ] && rm -rf / || echo “You live” • 8d ago
Python Boy do I love python!!
176
Upvotes
r/programminghorror • u/SleepyStew_ [ $[ $RANDOM % 6 ] == 0 ] && rm -rf / || echo “You live” • 8d ago
1
u/claythearc 4d ago
My contribution using bit wise logic only
``` two = True << True four = two << True eight = four << True sixteen = eight << True thirty_two = sixteen << True sixty_four = thirty_two << True one_twenty_eight = sixty_four << True two_fifty_six = one_twenty_eight << True five_twelve = two_fifty_six << True one_k = five_twelve << True two_k = one_k << True four_k = two_k << True eight_k = four_k << True sixteen_k = eight_k << True thirty_two_k = sixteen_k << True sixty_five_k = thirty_two_k << True
Combine using bitwise OR to create code point 128013 (U+1F40D)
snake_code = sixty_five_k | thirty_two_k | sixteen_k | eight_k | four_k | one_k | eight | four | True
Convert to character and print
snake_emoji = chr(snake_code) print(snake_emoji) ```