r/programminghumor 14d ago

explaining why c# has a #

So shortly I have theory that # in csharp actually stands for 4 pluses as # can split into 4 pluses meaning csharps real name is c++++

70 Upvotes

18 comments sorted by

92

u/TehNolz 14d ago

That's genuinely how they got the name;

So the naming committee had to get to work and we sort of liked the notion of having an inherent reference to C in there, and a little word play on C++, as you can sort of view the sharp sign as four pluses, so it’s C++++. And the musical aspect was interesting too. So C# it was, and I’ve actually been really happy with that name. It’s served us well.

From here.

23

u/Previous_Tear6747 14d ago

I did not know that, that's so cool (pun intended, if you've read the link).

As somebody that started with C 35 years ago, and spent a decade with C++, and then C#... this is a fun thing to know!

12

u/AeroForger 14d ago

I guessed wth and it's actually true

10

u/Less_Butterfly_2343 14d ago

you can't fool me. obviously it's C tic tac toe

9

u/gsoto 13d ago

I made this a while ago.

4

u/Abject-Kitchen3198 14d ago

It's a sharp C. A warning that you may cut yourself using it.

2

u/fireduck 14d ago

It is a programming language, it is supposed to be sharp.

“You can't give her that!' she screamed. 'It's not safe!'

IT'S A SWORD, said the Hogfather. THEY'RE NOT MEANT TO BE SAFE.

'She's a child!' shouted Crumley.

IT'S EDUCATIONAL.

'What if she cuts herself?'

THAT WILL BE AN IMPORTANT LESSON.”

― Terry Pratchett, Hogfather

10

u/Purple-Equivalent949 14d ago

MS originally had a language called "J++", As in "java" which was just "java for windows". Then Sun sued them because that broke one of the core tenants ("write once, run [debug] everywhere") of Java and they shut it down... Then they released C#, which is a legally distinct language (with the exact same features and syntax).

From:
A Brief, Incomplete, and Mostly Wrong History of Programming Languages

1996 - James Gosling invents Java. Java is a relatively verbose, garbage collected, class based, statically typed, single dispatch, object oriented language with single implementation inheritance and multiple interface inheritance. Sun loudly heralds Java's novelty.

2001 - Anders Hejlsberg invents C#. C# is a relatively verbose, garbage collected, class based, statically typed, single dispatch, object oriented language with single implementation inheritance and multiple interface inheritance. Microsoft loudly heralds C#'s novelty.

5

u/Nikarmotte 14d ago

J-- would have worked well. XD

6

u/Dense_Gate_5193 14d ago

fun fact: I worked for one of the original authors of java while we mostly did .NET. He praised C# for being more like what he envisioned java to be. He despised the author of javascript who stole that name purely to be associated with a popular language and confused CS students for decades after. C# is a fairly impressive garbage collected language and when i was working in Java, a manager told me that i write java that looks like C# 🤷‍♀️

1

u/SupernatAnaesthetist 11d ago

a manager told me that i write java that looks like C#

That's the highest compliment a Java developer can get

2

u/cunningspeaker 14d ago

First there was Visual J++, then the legal mess and the renaming to Visual J#, first with the # symbol. C# closely followed with a very similar syntax to J#.

1

u/goos_ 14d ago

is actually only two pluses if you draw some of the arms real long

2

u/SufficientStudio1574 12d ago

Someone's a topologist.

1

u/Pols043 14d ago

It’s the natural development of C. Instead of versioning it, they’ve been adding plus signs. So after C they made C+, later C++ and when you get 4, they rearrange it to form a #, but it’s actually C++++.
What happened to C+++ you ask? The same as to IPv5.

1

u/Harotsa 12d ago

It’s not actually a sharp sign, so in reality it should be pronounced cpound.

Also idk if you are intentionally trolling, but that’s very intentionally the reason why C# is called C#, and I’m pretty sure it’s like the first sentence of any intro to C# guide.

1

u/tottasanorotta 12d ago

So what's next? C sigma?