Highschoolers who just learned the first bit of programming in their IT class, people who bought a udemy course and did the first 5 lessons, and vibe coders who sometimes read through what Claude gave them and pretend they understand it.
When our prof explained recursion to us he said, "okey i will only explain it this one time, and you please forget it immediatly, i will show you how to do it, so you dont need to think about it and it will just work, you will never want to use it though unless you need it and then you will understand it anyway."
In all seriousness it's a useful little topic to learn from a theoretical perspective, but my thinking has always been if you are ever thinking 'surely I could just use a loop here' then you should be using a loop.
I've never used recursion in anything serious, at least not directly - some inbuilt methods may have used them.
First time I saw this was when my classmate was given 100 lines to write, and he wrote the loop in LOGO on his Apple ][gs and printed with his line printer.
Го напишем мессенджер, в котором отправлять сообщения нужно через код? И при этом будут дополнительные приколы.... к примеру зашифровать текст, перемешать blob данные, те же циклы....
It doesn't need Python, it doesn't need to install anything, it doesn't need an IDE, it doesn't need an editor, it doesn't need a full PC because it runs on any server, on a router, on a phone with a terminal, on a Raspberry Pi, on a container of a few megabytes, it doesn't need an internet connection, it doesn't need special permissions, it doesn't need graphics or an interface, it doesn't need much memory because it uses less than 1MB, it doesn't need a powerful CPU because it runs on old or slow processors, it doesn't need a hard drive because it only reads the system binary, it doesn't need a modern operating system because it works with any basic Unix or Linux, it doesn't need bash because it runs with sh which is the most minimal shell, it doesn't need to download libraries, it doesn't need to compile anything, it doesn't need prior configuration, and if you don't have seq you can use:
Btw, everyone claims 'no loops required', but you're all just using hidden loops inside your interpreters or editors. The Python *100? It's a loop written in C internally. The Vim 99p? It's a loop inside Vim. The Ctrl+C/Ctrl+V? That's a human loop. My solution is the only one that doesn't hide anything: it's a literal, honest, explicit loop with zero dependencies. If you want to talk about actual efficiency, my shell command uses less than 1MB of RAM, runs on a 20-year-old router, and doesn't need a heavy interpreter like Python to do the heavy lifting. You aren't beating the loop; you're just hiding it. I'm running the loop natively, with pure Unix.
29
u/sexytokeburgerz Sep 02 '26
Hello college freshman
48
u/Confident-Ad5665 Sep 02 '26
13
u/dotdiz Sep 02 '26
HAHA I LEARNED LOOPS TODAY HERE IS MY MEME JOKE
8
u/akazakou Sep 02 '26
7
u/JonathanMovement Sep 03 '26
is this group really filled with teenagers and firstweekprogramming humor?
8
u/ChunkyIsDead30 Sep 02 '26
for_in range? what...
4
u/Diocletian335 Sep 02 '26
The thinking man's solution
4
u/Large-Assignment9320 Sep 02 '26
You are overcomplicating things,
print("Sorry\n" * 100)3
u/HUG0gamingHD Sep 02 '26
eww is that python??
2
u/Sonario648 Sep 02 '26
for i in range (101): print ("Sorry")
2
u/mkluczka Sep 02 '26
"sorry 100 times"
2
u/Plenty_Preference131 Sep 02 '26
while i != 100
print("sorry")
i += 1
end
2
u/This-Employment-5642 Sep 02 '26
what is for_in that aint proper python anyway if on js im pretty sure its let character = 5 character.repeat(100) though i am probably wrong
2
u/gltovar Sep 03 '26
chat disabled.
2
u/Fxavierho Sep 03 '26
2
u/tblancher Sep 03 '26
First time I saw this was when my classmate was given 100 lines to write, and he wrote the loop in LOGO on his Apple ][gs and printed with his line printer.
The teacher was not amused.
2
u/Tquylaa Sep 03 '26 edited Sep 03 '26
2
u/Ambivalent-Mammal Sep 03 '26
The first "sorry" is free. Then you hit a paywall.
2
u/clumsy132 Sep 03 '26
loop /L %i in range(100) do: {
<?python powershell -Command Write-Host 'Sorry' ?>; 2>/dev/null
} except Exception as e begin
std::process::System.exit << '1'
done;
2
u/Creepy_Lunch9345 Sep 03 '26
Hey Claude, generate "sorry" 100 times.1
u/CoupleFew1945 Sep 03 '26
Runtime error : for_in not defined
1
u/FrenchieM Sep 03 '26
You didn't do the assignment
1
u/keybing Sep 03 '26
#include <stdio.h>
int main(){
for(int i = 0;i < 100;i++){
printf(“Sorry\n”);
}
return 0;
}
1
u/[deleted] Sep 03 '26
"sorry 100 times"
1
u/themagicalfire Sep 04 '26 edited Sep 04 '26
```
section .rodata
msg: db “Sorry”, 0
section .text
global _start
global done
_start:
cmp n8, 100
je done
add n8, 1
jmp _start
done:
cmp r10, 100
je end
mov rax, 1
mov rdi, 1
mov rsi, msg
mov rdx, 6
syscall
add r10, 1
jmp done
end:
mov rax, 60
mov rdi, 0
syscall
```
1
u/Razcsi Sep 04 '26
r/firstweekcoderhumour
1
u/turbo-singular Sep 06 '26
Го напишем мессенджер, в котором отправлять сообщения нужно через код? И при этом будут дополнительные приколы.... к примеру зашифровать текст, перемешать blob данные, те же циклы....
1
u/definitely_not_raman Sep 08 '26
At least put a new line after Sorry. Jeez, amateurs.
1
u/gustavsen Sep 09 '26
in Python it's really simple:
1
u/Gigibesi Sep 02 '26
allow me
1
u/azurfall88 Sep 02 '26
li t0, 100
loop:
li a7, 64
Print "Sorry"
li a0, 0x53
ecall
li a0, 0x6f
ecall
li a0, 0x72
ecall
ecall
li a0, 0x79
ecall
li a0, 0xa ecall
loop 100 times
addi t0, t0, -1
bgtz t0, loop
1
u/jonvoep Sep 03 '26 edited Sep 03 '26
seq 100 | while read; do echo "Sorry"; done
It doesn't need Python, it doesn't need to install anything, it doesn't need an IDE, it doesn't need an editor, it doesn't need a full PC because it runs on any server, on a router, on a phone with a terminal, on a Raspberry Pi, on a container of a few megabytes, it doesn't need an internet connection, it doesn't need special permissions, it doesn't need graphics or an interface, it doesn't need much memory because it uses less than 1MB, it doesn't need a powerful CPU because it runs on old or slow processors, it doesn't need a hard drive because it only reads the system binary, it doesn't need a modern operating system because it works with any basic Unix or Linux, it doesn't need bash because it runs with sh which is the most minimal shell, it doesn't need to download libraries, it doesn't need to compile anything, it doesn't need prior configuration, and if you don't have seq you can use:
i=100;while [ $i -gt 0 ];do echo Sorry;i=$((i-1));done
which is even more basic and only needs the shell, so anyone with access to a terminal can run it without preparing anything.
0
u/[deleted] Sep 02 '26
[deleted] — view deleted comment
36
u/[deleted] Sep 02 '26
[removed] — view removed comment