Global Feed Post Login
Replying to Avatar Vitor Pamplona

How I see programming languages:

C: You need to manually build a heap to run 1+1

Rust: Copy 1 15 times, add a copy of 1 and return a copy

Java: OnePlusOneStrategyBuilder is auto-injected

JavaScript: npm install OnePlusOne

Python: 1+1 -> Hey C, how much is 1+1?

Ruby: 1.plus(1) unless session_expired

SQL: Select from fake table with 1+1

Kotlin: Open Android Studio, Alt+Space, Enter.

Swift: (1+1) in a blue bubble or 11 in a green bubble

PHP:

Go: if err != nil { return nil } 1+1 if err != nil { return nil }

Avatar
ChipTuner 4mo ago

Awe that's unfair you don't need a heap to do 1+1 in C XD

Reply to this note

Please Login to reply.

Discussion

Avatar
Vitor Pamplona 4mo ago

I got a segfault just reading this.

Thread collapsed
Avatar
Scurvydog 4mo ago

But I like heaps

Avatar
ChipTuner 4mo ago

Big fan of heaps and arenas myself.

https://github.com/VnUgE/VNLib.Core/tree/develop/lib/Utils.Memory

Avatar
ChipTuner 4mo ago

But my favorite part, is that stack memory is enough to do a lot of work very fast.

Thread collapsed
Thread collapsed
Thread collapsed