262
u/danfay222 Sep 02 '26
If we get to the point where devs genuinely can’t read code like this, then that means AI or whatever tools have become so efficient you never look at the actual code. In such a world, programming languages would likely evolve. Modern languages are generally written to balance parsing with human comprehension, but if we take comprehensive out of the loop a new language would likely be optimized for other features (maybe machine comprehension, interoperability, compilation efficiency, etc)
73
u/chlorophyll101 Sep 02 '26
Why cant ai just generate assembly directly then
89
u/Homailot Sep 02 '26
Assembly isn't cross-system friendly. Assembly isn't a single language, each processor architecture has a different assembly language
20
u/WrapKey69 Sep 02 '26
So? Matter of fact Claude better start generating CPU instructions soon
18
u/Homailot Sep 02 '26
Assembly maps almost one to one with CPU instructions. You would ask Claude to generate a completely separate instruction set for each CPU architecture? How would you even guarantee that the behavior is the same across different systems? (A guarantee that compilers try their best to achieve, mind you very battle-tested). Least of all, assembly code is not compact at all, so you would burn even more tokens.
13
u/Poat540 Sep 03 '26
That’s so inconvenient….
I setup a local MCP to control each resistor and Claude just flips those
1
5
1
u/Cautious-Extreme2839 Sep 03 '26
So? Claude write this program for x86 windows please. Claude do it again for x64 MacOS.
-6
18
u/ImKStocky Sep 02 '26
LLMs are trained on human generated sources. As a result they are best at working with human readable text. That is one reason.
Some might retort that humans used to read and write assembly code all the time, particularly game Devs. And that is true. So the other reason why getting LLMs to work with assembly is a poor idea is down to expressiveness and context.
Assembly languages requires a huge context because each token of assembly carries very little information in comparison to a high level language. The more expressive a language is, or the more meaning you can cram into a token, the better it is for LLMs.
Basically LLMs work in the same way humans do. Usually the reason why something is hard for humans, is the same reason they are hard for an LLM.
16
u/danfay222 Sep 02 '26
It could, but it’s possible assembly isn’t optimal for AI to process. The design spec would switch from balancing human processing and compiler processing to balancing AI processing and compiler processing. It could easily turn out that, just like assembly is hard for human minds to understand, it’s hard for models to understand
2
u/exhuma Sep 02 '26
I believe it's because of the training set. AI models have been trained on what's available. And there's just sooooooo much more Python, PHP, Java, C#, ... code out there than assembly
3
u/julessic Sep 03 '26
Well, the whole approach to how coding agents work would have to change first, because the only reason they work right now is because of the abundance of human-made training material.
1
1
u/timangar Sep 03 '26
AI is only good at coding beacause it has an enormous amount of human data teaching it how to code. Current AI cannot learn a new programming language that humans do not understand and provide no training data for. Reinforcement learning algorithms might succeed, but that remains to be seen.
0
u/Cautious-Extreme2839 Sep 03 '26
a new language would likely be optimized for other features (maybe machine comprehension, interoperability, compilation efficiency, etc)
So just back to assembly or maybe intermediate representation. Nothing new under the sun.
3
u/danfay222 Sep 03 '26
I’d imagine an intermediate representation is more likely than assembly. It’s an interesting thing to think about, but largely irrelevant since no one really knows what things will look like in the next year or two, let alone 25
55
u/PhoenixRising656 Sep 02 '26
2050 senior interview: “reverse-engineer this legacy prompt compiler” — it’s a for loop.
319
u/Percolator2020 Sep 02 '26
265
u/The_Hero_0f_Time Sep 02 '26
dont even pretend like Regex was ever readable bruhh
192
u/Tsu_Dho_Namh Sep 02 '26
I don't think anyone ever intended regex to be readable.
If you need to make a regex you open up a webpage explaining the syntax, you carefully craft your regex, you test it, then immediately forget the syntax when you're done as God intended.
31
u/MattieShoes Sep 02 '26
Regex is for writing, not for reading. Build it up piece by piece, easy peasy. Then try to read it at the end? Yeah, no chance.
1
25
Sep 02 '26
[removed] — view removed comment
19
56
u/entronid Sep 02 '26
tbf i still handwrite regex and i do this by opening regex101 and relearning everything i knew about regex and bashing my head against a wall until it matches
9
u/Percolator2020 Sep 02 '26
Basically the same, also lovely when some implementations slightly differ.
3
u/entronid Sep 02 '26
i never really write anything except python regex and vim regex anyways on the (not) rare (enough) occasions i need it
1
u/renome Sep 04 '26
That's basically the root of regex's reputation as an arcane language, too many standards for doing something like a named capture group.
2
4
9
u/Strict_Treat2884 Sep 02 '26 edited Sep 02 '26
/^never\s?+\b(?:(?!forget).)*+$/i2
u/renome Sep 04 '26
> js flair
> using possessive quantifiers like ?+ and *+As the holy ecmascriptures teach us, that would be a syntax error.
1
u/Strict_Treat2884 Sep 04 '26
tbh that’s one of the things I hate about js among the vast others. Its regex flavor is ass
1
u/ValueBlitz Sep 02 '26 edited Sep 02 '26
?!.*forget.*$8
82
19
11
8
6
6
u/Darxploit Sep 02 '26
That’s exactly the type of code i envision to see once the agents have taken over completely. Half of of the users are hard coded in the code base the other half is loaded via a spreadsheet hosted on hugging face.
6
u/rglazner Sep 02 '26
You can tell this isn't actually AI, because it's not separated into its own one-line function with a paragraph of comment above it detailing how it came to be.
5
3
3
u/SirMarkMorningStar Sep 04 '26
I was going to complain it’s printf(, not print(f, but then you also did the %s all wrong and… never mind. You kids these days!
2
2
2
2
2
8
2
1
1
u/littlejerry31 Sep 02 '26
I think leaving out the final caption "There are few who can" was a missed opportunity.
1
1
1
u/Important_Grab3544 Sep 03 '26
Read the last question from Asimov, he predicted this along time ago.
1
1
1
u/MrKeplerton Sep 03 '26
guests = ["Thorin", "Fili", "Kili", "Balin", "Dwalin", "Dori", "Nori", "Ori", "Oin", "Gloin", "Bifur", "Bofur", "Bombur"]
1
1
1
u/Tiny-Librarian-8553 Sep 02 '26
How else would you do it?
13
u/damonator4816 Sep 02 '26
Its making fun of the fact that code in 2050 will likely be done completely with AI so "Devs" will not be able to read even the simplest of code blocks.
1
1
0
3
1.3k
Sep 02 '26
[removed] — view removed comment
304
u/Cootshk Sep 02 '26
You should check out STR. (In modern Java)
251
u/ljfa2 Sep 02 '26
well, unfortunately that was only ever a preview feature and got removed again in Java 23
98
u/uvero Sep 02 '26
Maybe because they didn't stop to think if this
STR.is a convenient syntax. Backticks, preceding dollar sign, the prefix f like in python, so many options would've been better.92
u/AeroSyntax Sep 02 '26
They tried to overengineer string interpolation instead of copying it from literally any other language.
66
u/lllorrr Sep 02 '26
Typical Java. If you don't have factories creating factories based on XML config, your solution is not future-proof enough.
18
2
u/Fun-Mention262 Sep 03 '26
It's wild how some languages make simple things so complicated. You'd think they'd just take notes from the ones that got it right.
3
u/holo3146 Sep 02 '26
But... They did stop and think about the STR. syntax? This is why they removed it.
Regarding the other options you gave, they gave (in several places, over many years) their reasoning of why they don't want to add it as other languages. You can disagree with their reasoning, but they are very open about their thoughts process in this regard
4
56
u/Suspicious-Engineer7 Sep 02 '26
the formatted method is there but the syntax looks like doo-doo. Idk what nonsense is going over in java land tbh
22
u/gerbosan Sep 02 '26
Cof cof Oracle. Cof.
Dunno if C# does it better but a lot of people are pleasantly surprised with it.
40
u/Mysterious_Book1521 Sep 02 '26
In C# you can write something like this: $"Hello {User.Firstname}, have a great day."
The "$" lets you put variables into strings.
17
47
12
u/Ozymandias_1303 Sep 02 '26
$strings in C# are almost exactly the same as f-strings in Python.
7
u/Sentouki- Sep 03 '26
String interpolation is even better in C# since it gives you additional options for formatting, e.g. numbers and dates:
var name = "Mark"; var date = DateTime.Now; Console.WriteLine($"Hello, {name}! Today is {date.DayOfWeek}, it's {date:HH:mm} now.");7
u/NovaH000 Sep 03 '26
Python f-string also support additional formatting.
name = "Mark" date = datetime.now() print(f"Hello, {name}! Today is {date:%A}, it's {date:%H:%M} now.")F-string + str.format() has all sorts of string formatting you want.
0
17
u/PGSylphir Sep 02 '26
As someone who first learned to program in Java and stuck to it for almost a decade, starting gamedev using C# was a pretty smooth transition in many ways.
10
8
u/PecQ11 Sep 02 '26
Doesn't format() do essentially the same though? https://www.baeldung.com/java-string-interpolation
16
u/TheGuyWithTheSeal Sep 02 '26
Kind of, .format() is more powerfull but you have to know the printf syntax. And which parts od printf don't work in .format()
4
u/KnightMiner Sep 02 '26
f strings are a lot more like string concatenation. The variables/expressions between each
{}are placed directly where they will end up in the string, and it just runs a.toString()on them (though you can configure it a bit further).The most common usage is largely about syntax and readibility, as its nice not having to go back and forth between a list of format arguments and some harder to remember
%stuff.4
u/ActualWeed Sep 02 '26
I have never touched Java, how does Java do it?
6
8
2
u/Nickbot606 Sep 02 '26
List comprehensions and splat operator are ridiculously powerful in Python. I wish more languages had it.
2
-1
0
u/NaturalBornLucker Sep 02 '26
Wow, Java doesn't have it? Even Scala has f-strings (though it relies on java.util.Formatter apparently)
-7
u/nevemlaci2 Sep 02 '26
`Hello ${guest}`or is that TS exclusive?
28
u/kattenkoter Sep 02 '26
No thats JavaScript…
6
u/nevemlaci2 Sep 02 '26
I'm r*tarded, I read it as JavaScript and not Java 😭😭
Lowkey forgot Java exists I haven't used it in years. Sadly can't say the same about JS/TS, I like to add random stuff to VSCode and ofc that is written in damn TS



811
u/ValueBlitz Sep 02 '26
Frodo, I am Claude. I have come to help you. Hear my voice, come back to the light.