Any funny algorithms for coding? | Sololearn: Learn to code for FREE!
Новый курс! Каждый программист должен знать генеративный ИИ!
Попробуйте бесплатный урок
0

Any funny algorithms for coding?

Hey! I have started with prime numbers finder (in my code) and I'm looking for some other entertaining algorithms. Please advice!

6th Sep 2018, 9:20 PM
Leszek Michalak
Leszek Michalak - avatar
1 ответ
+ 1
//not funny but an interesting one. //to find if the number is even or odd in a single line int n = 10; ((n & 1) && cout<<"Odd" ) || cout <<"Even";
7th Sep 2018, 2:07 AM
‎ ‏‏‎Anonymous Guy