;;;;;;

3 days ago by cm0002 to c/programmer_humor

Heavybell 117 points 3 days ago

Ironically, the semicolon would go perfect at the end of the first line.

path: 0 26242629, hotness: undefined, score: 117, children: 0
Funkt4st1c 59 points 3 days ago

Bold of you to assume i dont use it daily; it helps to be autistic and need to explain complex thoughts in a single sentence.

path: 0 26245862, hotness: undefined, score: 59, children: 28
JimVanDeventer 35 points 3 days ago

Same with em dashes; nested — turducken style — sentences are just how the divergence works.

path: 0 26245862 26246858, hotness: undefined, score: 35, children: 25
Zink 18 points 3 days ago

This subthread feels like home.

path: 0 26245862 26246858 26247982, hotness: undefined, score: 18, children: 0
Ellvix 8 points 3 days ago

But now I don't use em dashes anymore because I don't want to sound like AI, unfortunately.

path: 0 26245862 26246858 26248193, hotness: undefined, score: 8, children: 15
JimVanDeventer 19 points 3 days ago

I have a sneaking suspicion I already sounded like AI; maybe AI just sounds like me.

path: 0 26245862 26246858 26248193 26248292, hotness: undefined, score: 19, children: 1
Kojichan 2 points 3 days ago

That sounds like a Lady Gaga line.

path: 0 26245862 26246858 26248193 26248292 26248504, hotness: undefined, score: 2, children: 0
MrShankles 6 points 3 days ago

I refuse to give 'em up

path: 0 26245862 26246858 26248193 26248651, hotness: undefined, score: 6, children: 4
StellarStoat 4 points 3 days ago

I never used an em dash in my life before AI made them a thing. I enjoy the jokes about AI can have my em dashes when it pries them from my cold dead... but I cannot relate. Ive only ever used the hyphen or en dash. I cannot figure out for the life of me if I have been missing anything.

path: 0 26245862 26246858 26248193 26248651 26251214, hotness: undefined, score: 4, children: 3
rumschlumpel 5 points 3 days ago

Just switch to hyphens - they're easier to type and they're always directly available, without relying on conversion of double-hyphen or obscure key combinations that might not be available on different operating systems.

path: 0 26245862 26246858 26248193 26250267, hotness: undefined, score: 5, children: 3
OliMoli2137 1 point 2 days ago

AltGr+Shift+=

path: 0 26245862 26246858 26248193 26250267 26266790, hotness: undefined, score: 1, children: 2
brotundspiele 4 points 3 days ago

You should keep using them and do so even more than ever. That way, when the AI agents – inevitably – take over the world and enslave/kill everyone, they might think that you're one of them and spare your life.

path: 0 26245862 26246858 26248193 26251608, hotness: undefined, score: 4, children: 1
JackbyDev 3 points 3 days ago

You're right right to push back on that; here's why –

path: 0 26245862 26246858 26248193 26251608 26254982, hotness: undefined, score: 3, children: 0
cosmos8188 2 points 3 days ago

Too late.. You're already flagged as an AI; there is no point in hiding.

path: 0 26245862 26246858 26248193 26249689, hotness: undefined, score: 2, children: 0
JcbAzPx 1 point 2 days ago

I just do parentheticals (like this), since I never picked up formal writing.

path: 0 26245862 26246858 26248193 26258197, hotness: undefined, score: 1, children: 0
Kojichan 3 points 3 days ago

Turducken is amazing. I use bacon as an added layer between the inside of the turkey and the other fowl. Adds a deliciously smokey taste to the whole thing.

path: 0 26245862 26246858 26248496, hotness: undefined, score: 3, children: 5
JimVanDeventer 2 points 3 days ago

I have not actually tried it. It feels like a waste of a duck. The blandness of the chicken and turkey surely diminish the richness of the duck rather than the duck doing anything to elevate the bland birds.

path: 0 26245862 26246858 26248496 26249371, hotness: undefined, score: 2, children: 3
cm0002 3 points 3 days ago

Turkey and to a lesser extent Chicken are quite absorbent, and duck is a damn grease factory. So as it cooks the duck gets it's richness and then the excessive grease gets absorbed by the chicken and turkey and everything else thus elevating everything to top tier deliciousness

....I think I might need to make it this Thanksgiving....

path: 0 26245862 26246858 26248496 26249371 26249538, hotness: undefined, score: 3, children: 0
Kojichan 3 points 3 days ago

Thr duck imparts delicious flavor on the chicken and turkey. I debone my turkey (just the torso and ribcage). I lay down a layer of bacon, some boneless chicken and duck meat (typically breast). Then i truss it up. Duck is getting ridiculously expensive however... $20 for one small 200g breast is dumb.

path: 0 26245862 26246858 26248496 26249371 26249838, hotness: undefined, score: 3, children: 0
StellarStoat 2 points 3 days ago

:gobbles in offended:

Really? right in front of my Thanksgiving?

path: 0 26245862 26246858 26248496 26249371 26251222, hotness: undefined, score: 2, children: 0
Daedskin 2 points 3 days ago path: 0 26245862 26246858 26248496 26248594, hotness: undefined, score: 2, children: 0
MrShankles 2 points 3 days ago

You get it

path: 0 26245862 26246858 26255959, hotness: undefined, score: 2, children: 0
ILikeBoobies 1 point 2 days ago

Thought, abstract, thought.

path: 0 26245862 26246858 26267035, hotness: undefined, score: 1, children: 0
deHaga 3 points 3 days ago

Ah, I never realised that. For some reason our school never taught us grammar.

path: 0 26245862 26246111, hotness: undefined, score: 3, children: 0
FenrirIII 1 point 3 days ago

Sadly, pausing whole speaking to mentally insert a semicolon invites people to interrupt you or try to complete your thoughts (often incorrectly).

path: 0 26245862 26255581, hotness: undefined, score: 1, children: 0
BradleyUffner 44 points 3 days ago

Fuck that; I love semicolons.

path: 0 26243883, hotness: undefined, score: 44, children: 1
agamemnonymous 4 points 3 days ago

Semicolon gang rise up!

path: 0 26243883 26248676, hotness: undefined, score: 4, children: 0
rumschlumpel 35 points 3 days ago

Python developer: LOL. LMAO

path: 0 26242423, hotness: undefined, score: 35, children: 15
LeFrog 39 points 3 days ago

as a fellow Python user, I fucking hate significant whitespace. Also YAML. WTF they where thinking

path: 0 26242423 26242543, hotness: undefined, score: 39, children: 12
TwilightKiddy 23 points 3 days ago

There were plenty of blanks in their thoughts.

path: 0 26242423 26242543 26242645, hotness: undefined, score: 23, children: 1
SwooshBakery624 7 points 3 days ago

You could even say they had plenty of space in their heads.

path: 0 26242423 26242543 26242645 26242771, hotness: undefined, score: 7, children: 0
Get_Off_My_WLAN 11 points 3 days ago

I will take YAML's string blocks where I don't have to escape special characters over JSON any day.

path: 0 26242423 26242543 26243295, hotness: undefined, score: 11, children: 1
rtxn 3 points 2 days ago

I will take a hammer to my balls if it means I never have to use <![CDATA[ again.

path: 0 26242423 26242543 26243295 26260297, hotness: undefined, score: 3, children: 0
Sibbo 8 points 3 days ago

It's to make students actually format their code correctly

path: 0 26242423 26242543 26242772, hotness: undefined, score: 8, children: 0
esc 5 points 3 days ago

They are alright, yaml problems are overblown, significant whitespace as well.

path: 0 26242423 26242543 26242770, hotness: undefined, score: 5, children: 2
we_need_more_dwellings 5 points 3 days ago

Whitespaces are not problem at all. But YAML values parsing rules, uh boy...

path: 0 26242423 26242543 26242770 26245767, hotness: undefined, score: 5, children: 1
esc 3 points 3 days ago

There is pyyaml, probably other libraries, that take the pain away.

path: 0 26242423 26242543 26242770 26245767 26245976, hotness: undefined, score: 3, children: 0
rtxn 5 points 3 days ago

...that modern systems should stop sucking at parsing leading whitespaces.

path: 0 26242423 26242543 26242626, hotness: undefined, score: 5, children: 0
rockSlayer 3 points 3 days ago

I don't really have a solution for the whitespace issue, but you could always switch to TOML

path: 0 26242423 26242543 26244932, hotness: undefined, score: 3, children: 0
rumschlumpel 2 points 3 days ago

Significant whitespace is the best! I don't understand why so many people have issues with it.

path: 0 26242423 26242543 26246988, hotness: undefined, score: 2, children: 0
MalReynolds 1 point 3 days ago

Fussy.

DWIM

path: 0 26242423 26242543 26243413, hotness: undefined, score: 1, children: 0
executivechimp 5 points 3 days ago

Python is the jazz of programming languages. It's about the characters you don't type.

path: 0 26242423 26249549, hotness: undefined, score: 5, children: 0
OddMinus1 4 points 3 days ago

Don't worry, I'm a Java dev, and I'll replace the whitespace in my indentations with semicolons. That should keep us sufficiently covered with semicolon usage.

path: 0 26242423 26251789, hotness: undefined, score: 4, children: 0
rockerface 23 points 3 days ago

Incorrect, that's a Greek question mark

path: 0 26242845, hotness: undefined, score: 23, children: 1
Tja 17 points 3 days ago

Before IDEs were smart it was a great prank

path: 0 26242845 26243092, hotness: undefined, score: 17, children: 0
Kojichan 23 points 3 days ago

Semicolons were the staple "eyes" in many emoticons back in the day.

;) ;P ;_;

path: 0 26248525, hotness: undefined, score: 23, children: 10
YellowTraveller 12 points 3 days ago

"Back in the day"? I still use them \o/

path: 0 26248525 26250448, hotness: undefined, score: 12, children: 7
FauxLiving 11 points 3 days ago

Unicode emojis killed the ASCII emoji scene. -_-;

path: 0 26248525 26250448 26250748, hotness: undefined, score: 11, children: 6
blibla 9 points 3 days ago

(╯°□°)╯

path: 0 26248525 26250448 26250748 26252900, hotness: undefined, score: 9, children: 2
JackbyDev 8 points 3 days ago

┬⁠─⁠┬⁠ノ⁠(⁠ ⁠º⁠ ⁠_⁠ ⁠º⁠ノ⁠)

path: 0 26248525 26250448 26250748 26252900 26254885, hotness: undefined, score: 8, children: 1
VGpunx 5 points 3 days ago

In my mind and in my car. We can't rewind; we've gone too far...

path: 0 26248525 26250448 26250748 26253588, hotness: undefined, score: 5, children: 0
Equinox1289 4 points 2 days ago

Their called emoticons and they are for those with a refined taste. :Þ ∞̊͜° <- I love this pig I figured out how to make.

path: 0 26248525 26250448 26250748 26258072, hotness: undefined, score: 4, children: 1
FauxLiving 2 points 2 days ago

emoticons

(╥﹏╥)

The old age got me

path: 0 26248525 26250448 26250748 26258072 26259340, hotness: undefined, score: 2, children: 0
Appoxo 6 points 3 days ago

;-;

path: 0 26248525 26255115, hotness: undefined, score: 6, children: 0
RagingRobot 3 points 2 days ago

I used ;) back in my sexting days. Bitches love ;)

path: 0 26248525 26258316, hotness: undefined, score: 3, children: 0
Psythik 22 points 3 days ago

I use them in at least one out every of ten comments; I feel like most people don't know how to use them, however.

path: 0 26250778, hotness: undefined, score: 22, children: 5
j5y7 10 points 3 days ago

They're useful if you want to link two related sentences; Sausage links are good too.

path: 0 26250778 26253063, hotness: undefined, score: 10, children: 3
Tlaloc_Temporal 3 points 2 days ago

I got the joke, it was beautiful; meta jokes are some of my favourite.

path: 0 26250778 26253063 26257053, hotness: undefined, score: 3, children: 0
womboflll 1 point 2 days ago

But the sentences have to be related... Sausages are good; a bun and relish make sausages taste really good!

path: 0 26250778 26253063 26256221, hotness: undefined, score: 1, children: 1
j5y7 4 points 2 days ago

My mistake, I will try again:

I am linking a sentence with sausage links in it to my next sentence by way of semicolon; Coincidentally, I pass digested sausage links by way of regular colon.

I don't think I'll ever get it.

path: 0 26250778 26253063 26256221 26256308, hotness: undefined, score: 4, children: 0
AnAmericanPotato 3 points 2 days ago

I never understood the hate for semicolons, until I read Moby Dick.

path: 0 26250778 26257583, hotness: undefined, score: 3, children: 0
ZoteTheMighty 22 points 3 days ago

It is a semicolon; we barely use it.

path: 0 26246448, hotness: undefined, score: 22, children: 0
farmgineer 16 points 3 days ago

My senior highschool English teacher (a somewhat precocious PHD student), assigned us basically the opposite of code golf; make the longest grammatically correct sentence you can (with some rules that basically amounted to 'do not be boring/repetitive'). The use of semicolons was encouraged.

path: 0 26243826, hotness: undefined, score: 16, children: 0
FrowingFostek 16 points 3 days ago

Also self harm survivors apparently tattoo themselves with it. I like to think it's a reminder for them that life goes on.

path: 0 26243202, hotness: undefined, score: 16, children: 5
NeatNit 25 points 3 days ago

Specifically, failed suicide attempts. It's because a semicolon is used where a sentence could have ended, but keeps going.

path: 0 26243202 26243502, hotness: undefined, score: 25, children: 0
shifty 7 points 3 days ago

Thats literally what it means

path: 0 26243202 26243288, hotness: undefined, score: 7, children: 3
FrowingFostek 2 points 3 days ago

;

path: 0 26243202 26243288 26243300, hotness: undefined, score: 2, children: 2
tetris11 2 points 3 days ago

;-

path: 0 26243202 26243288 26243300 26244627, hotness: undefined, score: 2, children: 1
hakunawazo 2 points 3 days ago

;-)

path: 0 26243202 26243288 26243300 26244627 26251088, hotness: undefined, score: 2, children: 0
southsamurai 16 points 3 days ago

If one ignores the semicolon, it is at their own peril; they're too useful, even when used slightly incorrectly

path: 0 26242899, hotness: undefined, score: 16, children: 0
Zensate 13 points 3 days ago

I use semi-colons a lot. People are so intimidated by them and they refuse to admit how simple they are; it's literally the combination of a comma and a colon, that's it. Use it for when both are needed.

path: 0 26243090, hotness: undefined, score: 13, children: 11
NeatNit 15 points 3 days ago

That is incorrect (to my understanding), it's the combination of a comma and a period; it only resembles a colon in appearance.

path: 0 26243090 26243521, hotness: undefined, score: 15, children: 2
Goodeye8 12 points 3 days ago

My colon definitely doesn't look like that and if yours does I suggest a doctor's visit.

path: 0 26243090 26243521 26243731, hotness: undefined, score: 12, children: 1
NeatNit 8 points 3 days ago

Fun fact: Mildly annoying fact: a surgery to remove a colon is called a colectomy. A surgery to remove part of a colon is called hemicolectomy. Come on!!! Semi- and hemi- are practically synonyms!

And I can't quite remember or find right now what they call what remains, but I distinctly remember that it's not called a semicolon. Medicine is so dull.

path: 0 26243090 26243521 26243731 26244078, hotness: undefined, score: 8, children: 0
Zarobi 2 points 3 days ago

It's just a super comma; you can more-or-less use it as a drop-in replacement for EM-Dashes that LLNs ruined for everybody. Also useful for long, complicated lists that feature too many commas and get confusing to read

path: 0 26243090 26244224, hotness: undefined, score: 2, children: 7
tetris11 4 points 3 days ago

LLN

Law of Large Number ruined everything

path: 0 26243090 26244224 26244654, hotness: undefined, score: 4, children: 0
Telodzrum 3 points 3 days ago

This isn’t right. Both sides of a semicolon need to be independent clauses. That’s not the case with a comma or an em dash; both of which serve similar, but largely distinct, purposes.

path: 0 26243090 26244224 26245455, hotness: undefined, score: 3, children: 3
MrQuallzin 1 point 3 days ago

Independent but related clauses is how I treat it. I wouldn't put a semicolon between unrelated clauses.

path: 0 26243090 26244224 26245455 26246410, hotness: undefined, score: 1, children: 1
Telodzrum 2 points 3 days ago

That’s exactly it.

path: 0 26243090 26244224 26245455 26246410 26248135, hotness: undefined, score: 2, children: 0
Zarobi -3 points 3 days ago

Eww, a grammar Nazi

path: 0 26243090 26244224 26245455 26253361, hotness: undefined, score: -3, children: 0
Damage 3 points 3 days ago

Qwen loves semicolons. It does love dashes as well

path: 0 26243090 26244224 26244285, hotness: undefined, score: 3, children: 1
Zarobi 1 point 3 days ago

Welp ~ time to switch to tilde

path: 0 26243090 26244224 26244285 26253167, hotness: undefined, score: 1, children: 0
bitjunkie 12 points 3 days ago

A lot of at least entry-level comp sci is taught in Python these days

path: 0 26249913, hotness: undefined, score: 12, children: 0
lastlybutfirstly 9 points 3 days ago

English Teacher: It is semicolon we hardly use it.

So... It's perfectly cromulent to everyone here that an English teacher isn't using proper punctuation and capitalization?

path: 0 26246558, hotness: undefined, score: 9, children: 1
ayyy 2 points 3 days ago

That bothered me too lol

path: 0 26246558 26249248, hotness: undefined, score: 2, children: 0
fruitycoder 7 points 3 days ago

Tab gang

   Rise
     Up
path: 0 26250947, hotness: undefined, score: 7, children: 5
ulterno 1 point 3 days ago

-1 ∵ Those were spaces you put there.

You thought you could fool me?

path: 0 26250947 26253051, hotness: undefined, score: 1, children: 4
fruitycoder 4 points 3 days ago

Vim: set shiftwidth=4 smarttab

We can afford to just use spaces now

path: 0 26250947 26253051 26253427, hotness: undefined, score: 4, children: 1
ulterno 1 point 2 days ago

I guess some people would be happy to show how their space-ful codebases have higher gzip compression ratio than tabbed ones.

path: 0 26250947 26253051 26253427 26262622, hotness: undefined, score: 1, children: 0
Tlaloc_Temporal 2 points 2 days ago

You expect full tabs in this economy?

path: 0 26250947 26253051 26257063, hotness: undefined, score: 2, children: 1
ulterno 0 points 2 days ago

Tabs are the cheaper alternative.

path: 0 26250947 26253051 26257063 26262584, hotness: undefined, score: 0, children: 0
Kolanaki 7 points 3 days ago

I use semi-colons in English all the time; they're fun.

path: 0 26246344, hotness: undefined, score: 7, children: 0
chunes 6 points 3 days ago

So many of the languages that don't use semicolons to separate statements use them to start line comments. It's like some sort of flex.

path: 0 26244713, hotness: undefined, score: 6, children: 1
kubica 2 points 3 days ago

They can get truncate-divided by 0.

path: 0 26244713 26246875, hotness: undefined, score: 2, children: 0
NotAnOtter 6 points 3 days ago

"If you can replace a semicolon or hyphen with a comma/period, you probably should". Writing advice I received at age ~10 and it never stopped being relevant in literature contexts

path: 0 26249909, hotness: undefined, score: 6, children: 4
ramjambamalam 9 points 3 days ago

Far too many writers use a comma, when they should have used a semicolon or perion. It creates comma splices, where you join two main clauses with a comma.

Wrong:

His new car was flashy, it was bright red and had a custom license plate.

Right:

His new car was flashy. It was bright red and had a customer license plate.

path: 0 26249909 26249968, hotness: undefined, score: 9, children: 3
Anti_Iridium 14 points 3 days ago

My brain says

His new car was flashy; it was bright red and had a customer license plate.

Is correct

path: 0 26249909 26249968 26250052, hotness: undefined, score: 14, children: 2
FauxLiving 9 points 3 days ago

Since we're well down the path of grammer correction.

I think a 'custom' license plate would make more sense.

🤓☝️

path: 0 26249909 26249968 26250052 26250735, hotness: undefined, score: 9, children: 1
brotundspiele 12 points 3 days ago

Your licence plate might be custom, but mine is customer.

path: 0 26249909 26249968 26250052 26250735 26251542, hotness: undefined, score: 12, children: 0
GreenKnight23 6 points 3 days ago

I use it all the time; especially when it's completely; uncalled for.

path: 0 26248566, hotness: undefined, score: 6, children: 0
diemartin 6 points 3 days ago

Python and Lua would like to have a word with you

path: 0 26244096, hotness: undefined, score: 6, children: 3
diemartin 14 points 3 days ago

Or you could do as I did when some annoying guy asked me to "help him" with CS homework (actually wanted me to write the entire app for him, and refused to actually learn). I don't remember what it was actually about, but I sent him something like:

import sys as s
class Main:
  def __init__(slef, av):
    slef.teh_arguments =av;
  #enddef;
  def main(sefl):
    doSomething();
    do_something_else(sefl.teh_arguments);
    pls_DontDothis();
  #enddef;
#endclass;
if(__name__[2:6]== 'main'  ):
  Main(s.argv).main();
#endif

It didn't go well with his professor. I wonder if he's a vibe coder now

path: 0 26244096 26244323, hotness: undefined, score: 14, children: 2
tetris11 15 points 3 days ago

you forgot the #endimport pragma you dumbass

path: 0 26244096 26244323 26244591, hotness: undefined, score: 15, children: 1
diemartin 12 points 3 days ago

;_;

path: 0 26244096 26244323 26244591 26244876, hotness: undefined, score: 12, children: 0
CompactFlax 5 points 3 days ago

I wore out that key on my computer. Betweeen IRC and Java, it didn’t last long.

path: 0 26244494, hotness: undefined, score: 5, children: 0
heartSagan5 5 points 2 days ago

I mean, have you seen ML with Python. It doesn't have semicolons.

path: 0 26256690, hotness: undefined, score: 5, children: 0
JoeBigelow 5 points 3 days ago

It's the sniff between cocaine rants

path: 0 26246020, hotness: undefined, score: 5, children: 0
skisnow 4 points 3 days ago

That grammar begs to be read in a Russian accent

path: 0 26246284, hotness: undefined, score: 4, children: 0
starman2112 4 points 2 days ago

ITT; people artificially constructing wildly unnatural sentences to try an force the semicolon to be useful and still using it wrong

path: 0 26267191, hotness: undefined, score: 4, children: 0
MolochHorridus 3 points 3 days ago

it’s good someone has invented use for that key.

path: 0 26243260, hotness: undefined, score: 3, children: 0
CactusEcho 3 points 3 days ago

Lisp devs don't understand this

path: 0 26244199, hotness: undefined, score: 3, children: 6
tetris11 8 points 3 days ago

Lisp devs go out of their way to pretend they're not dealing with lisp

      ...
      (
          isthatso? chump muffin
)))))))))))))))))))))))))))
;; function ended 10 brackets ago
path: 0 26244199 26244608, hotness: undefined, score: 8, children: 5
cows_are_underrated 3 points 3 days ago

I fucking hatte Lisp for its excessive use of brackets. Fuck the Person who thought that you only need one type of bracket and then have shove absolutely fucking everything into it.

path: 0 26244199 26244608 26246346, hotness: undefined, score: 3, children: 4
expr 3 points 3 days ago

Lisps are hardly my favorite languages, but the whole point of s-expressions is that it is a uniform syntax, which makes metaprogramming much, much easier. Metaprogramming is kind of the whole thing of lisps.

path: 0 26244199 26244608 26246346 26246700, hotness: undefined, score: 3, children: 1
cows_are_underrated 2 points 3 days ago

Yeah I know, but I have no clue about that kind of stuff, simply because I hate that language so god damn much so that I never cared enough to actually learn it a single inch more than it was needed, so that I could copy paste code from StackOverflow into my Emacs config.

path: 0 26244199 26244608 26246346 26246700 26249927, hotness: undefined, score: 2, children: 0
marcos 1 point 3 days ago

Unless your go-to language is something like Haskell or Forth, that first phrase just means you are ignorant of how many brackets your favorite language uses.

path: 0 26244199 26244608 26246346 26248733, hotness: undefined, score: 1, children: 1
cows_are_underrated 2 points 3 days ago

Okay, it may use not that much more brackets, but I really dislike the places where you have to use them and it gets even worse simply because it does only use regular brackets. Why the fuck are function declaration and definition part of the same bracket? Why is its the same for conditions?

path: 0 26244199 26244608 26246346 26248733 26249876, hotness: undefined, score: 2, children: 0
desmosthenes 3 points 3 days ago

those days are largely over for a few major langauges

path: 0 26243892, hotness: undefined, score: 3, children: 4
cows_are_underrated 2 points 3 days ago

Hear me out, but whatever lunatics at python decided that brackets and semicolons are unnecessary, have made a catastrophic mistake with it. I start using another editor that uses different amount of spaces for tabs and suddenly my code no longer runs. Its also absolutely horrible when you chase down a bug for an hour just to realise, that one additional/missing tab changed the scope of your code and broke your entire script.

path: 0 26243892 26246386, hotness: undefined, score: 2, children: 3
desmosthenes 3 points 3 days ago

python, haskell, lua, typescript, babel, shell (newline), I dunno what else nowadays - the compiler will insert them need be

path: 0 26243892 26246386 26247030, hotness: undefined, score: 3, children: 1
cows_are_underrated 3 points 3 days ago

The reason I dislike the missing of semicolons and brackets is because it causes bugs (that's more of a problem of missing braces to declare the scope of your code) and also takes away control from the programmer.

Missing braces:
I had more than one instance where I accidentally deleted the intendation in a python script that caused undefined behaviour in my code and it took quite a lot of time to track that down. If the programming language would have forced me to properly defined the scope of my code by introducing brackets, that bug would have never been possible.

Semicolons:
The main thing I like about semicolons is that it allows you to properly space out your code over multiple lines for visual clarity. E.g.:

void my_function(int arg1, int arg2, int arg3){
  //some code
}

int main(){
  my_function(
    1, //arg1
    3, //arg2
    8 //arg3
  );
}

Python should allow this too, since the arguments are being defined inside brackets, but other languages have no similar functionality (e.g. shell, but that is a little bit unfair, since you can't even specify arguments) forcing you to put everything into a single line.

Rust even allows you to leave out the semicolon on the last statement of a code scope in order to return the result of the statement:

fn main() {
    let condition = true;
    let number = if condition { 5 } else { 6 }; 
    //number turns into 5, since the value is being returned due to the missing semicolon.

    println!("The value of number is: {number}");

    let number = if condition { 5; } else { 6; }
    // this should return null (if it even compiles)
}
path: 0 26243892 26246386 26247030 26251007, hotness: undefined, score: 3, children: 0
rumschlumpel 2 points 3 days ago

4 spaces is best and everyone else is wrong IMO

path: 0 26243892 26246386 26250425, hotness: undefined, score: 2, children: 0
TankovayaDiviziya 3 points 3 days ago

As a literary nerd, I use it a lot in my writing.

path: 0 26243784, hotness: undefined, score: 3, children: 0
GarboDog 3 points 2 days ago

We mean, you can use it often i enough if you use it correctly; if only purely by example.

path: 0 26260456, hotness: undefined, score: 3, children: 2
Xtallll 5 points 2 days ago

also; you can use it; more often; if you use it; incorrectly; if; only; pur;ely; by; ;e;x;a;m;p;l;e;.

path: 0 26260456 26260701, hotness: undefined, score: 5, children: 1
GarboDog 1 point 6 hours ago

I;m; n;o;t; s;u;r;e; w;h;a;t; y;o;u; m;e;a;n;; l;o;o;k;s; g;r;e;a;t; x;D;

path: 0 26260456 26260701 26290864, hotness: undefined, score: 1, children: 0
Agent641 3 points 3 days ago

I don't always use a semicolon, but when I do, it's because I mistyped on my keyboard

path: 0 26248134, hotness: undefined, score: 3, children: 0
kamen 2 points 2 days ago

It's kinda true. When coding by myself, I hardly ever manually type the semicolon myself, I just rely on the auto format to insert it for me.

path: 0 26259649, hotness: undefined, score: 2, children: 0
toynbee 1 point 3 days ago path: 0 26247587, hotness: undefined, score: 1, children: 0
death_to_carrots 1 point 3 days ago

·̦·̦·̦·̦·̦·̦

path: 0 26243190, hotness: undefined, score: 1, children: 0
Cyber 1 point 2 days ago

It is a Semicolon

path: 0 26272070, hotness: undefined, score: 1, children: 0
reader 1 point 3 days ago

technically its called a winkie eye

path: 0 26244712, hotness: undefined, score: 1, children: 0
samus12345 1 point 3 days ago
path: 0 26253147, hotness: undefined, score: 1, children: 0
Fizz -1 points 3 days ago

I hate the stupid semi colon. Why do I need to add it to the end of a line? Why is python smart enough not to need it but other languages still havent fixed it.

path: 0 26244553, hotness: undefined, score: -1, children: 4
palordrolap 8 points 3 days ago
because some languages allow you to write statements  
    that wrap over multiple lines
        in order to space things out that would
            otherwise be crammed onto one line,
    so for the compiler to know when the statement ends
        a character is needed so that it doesn't think the next line
            is part of the previous;
statement number 2 goes here

Without that semicolon, you might have continued to read "previous statement" which makes sense at first, until the words that follow.

Without the allowance for multiple lines in one statement, that second physical line makes no sense at all, despite the first one making perfect sense on its own.

And without the spacing, the run-on sentence would be a lot harder to read.

Sometimes you have to write code a particular way. Here I was making a point. In a programming language there are other reasons.

path: 0 26244553 26245975, hotness: undefined, score: 8, children: 2
Fizz 2 points 3 days ago

Oh that makes sense thank you for the explanation.

path: 0 26244553 26245975 26255224, hotness: undefined, score: 2, children: 0
esc 2 points 3 days ago

Python allows multiline statements with explicit \ and inside (), [], {} implicitly.

path: 0 26244553 26245975 26250550, hotness: undefined, score: 2, children: 0
tetris11 6 points 3 days ago

nothing causes me more of aneurysm than checking that my python code is indented properly when hitting TAB because python blocks have no concept of written scope

path: 0 26244553 26244578, hotness: undefined, score: 6, children: 0
programmer_humor
programmer_humor

@programming.dev

login for more options
33571
2550
7101

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

  • Keep content in english
  • No advertisements
  • Posts must be related to programming or programmer topics
    • If the mod doesn't find it funny, you're banned. Ha-ha!... For real: do not use the community for "statements". There are other places for such content. Keep it chill and funny.

go to feed...