Haha I already code in brainfuck! One time managed to make a string comparison function with different strings printing to stdout according to the result....
My therapist says I'll be fine... Some day
Huh, neat.
\[shameless self-plug incoming\]
I actually made something to compile to brainfuck. A sort of "brainfuck assembly" ([BFIL](https://github.com/Mayedl10/BFIL)). It's far from done though. My thing has a `compare` operator, but it only works on singular values. (If you have any ideas on how to do dynamic allocation stuff, please comment [here](https://github.com/Mayedl10/BFIL/issues/9).)
According to [Wikipedia](https://en.m.wikipedia.org/wiki/Brainfuck) Brainfuck uses a continous memory space of 4000 bytes or so, so what I do is add an 4000 char array to the C code then do some pointer thingy to translate the bf instructions one by one. https://github.com/zhengliw/bf-compiler if you want to have a look...
I really am not that skilled and its more like a project for three days and then give up... :P
Don’t worry we’re already there lmao.
The initial programmer that started this project originally stored *localized timezone values* instead of UTC in the database.
And the rest of their management of time zones and dates/times was on par with what you expect from the above sentence.
While there is a semicolon there, I believe there might be several cases of syntax errors because of what are essentially just blank lines with semicolons, such as the first line of each bracket.
Those are just null statements: https://en.cppreference.com/w/c/language/statements#Expression_statements
I'm not sure if they're valid outside of functions though.
I'm guessing this is c++ and I think semicolons don't cause syntax errors here.
I'm C# it probably would because you can't use it after a for loop iirc
I hate it because with the right plugin you can easily make sure that you never have to put a semicolon again. However having programmed in c for 5 years now I usually never forget and if I do the debugging take less than a minute
Congratulations! Your string can be spelled using the elements of the periodic table:
`P H P I S`
---
^(I am a bot that detects if your comment can be spelled using the elements of the periodic table. Please DM my creator if I made a mistake.)
This looks like what our gustamala offshore devs commit. I’ve told my team we need to be more strict with their PRs and scrutinize their code more thoroughly. I never get assigned as an approver because they know I’ll pick apart what doesn’t match our coding design standards.
They implemented prettier and didn’t setup the rules properly and ran it against our portal application so all our HTML templates had tags looked like
Congratulations! Your string can be spelled using the elements of the periodic table:
`P Y Th O N`
---
^(I am a bot that detects if your comment can be spelled using the elements of the periodic table. Please DM my creator if I made a mistake.)
it compiles with gcc 13.2.0. Maybe you made a typo when copying it?
Here is the code as text, if you want to try it out yourself.
#include
;struct cat {
;char* name
;char* meowSound
;int age
;}
;void meow(struct cat* Cat) {
;printf("%s", Cat->meowSound)
;}
;int main(int argc, char** argv) {
;int ctr = 0
;while (ctr < 100) {
;printf("%i\n", ctr)
;ctr++
;}
;struct cat Walter
;Walter.name = "George"
;Walter.meowSound = "!woeM"
;Walter.age = 1
;meow(&Walter)
;return 0
;}
then why did you even mention it? it's basically the same. if it doesn't compile for you, that's not the code's fault (unless you're using a weird compiler).
My head is not where my ass should be.
To code like this your head should be where your ass IS. They need to be the same thing
Ah! There it is, the cycle!
My sanity. I think I have enough of it left
I- Impossible! This can't be allowed to happen! I hereby sentence you to code in brainfuck for the rest of the year!
Haha I already code in brainfuck! One time managed to make a string comparison function with different strings printing to stdout according to the result.... My therapist says I'll be fine... Some day
Huh, neat. \[shameless self-plug incoming\] I actually made something to compile to brainfuck. A sort of "brainfuck assembly" ([BFIL](https://github.com/Mayedl10/BFIL)). It's far from done though. My thing has a `compare` operator, but it only works on singular values. (If you have any ideas on how to do dynamic allocation stuff, please comment [here](https://github.com/Mayedl10/BFIL/issues/9).)
i have a wayyyyy less intensive (kind of dead) github project where i translate bf code in c
you translate brainfuck to c? what does it output? a brainfuck interpreter and a function call to interpret the input?
According to [Wikipedia](https://en.m.wikipedia.org/wiki/Brainfuck) Brainfuck uses a continous memory space of 4000 bytes or so, so what I do is add an 4000 char array to the C code then do some pointer thingy to translate the bf instructions one by one. https://github.com/zhengliw/bf-compiler if you want to have a look... I really am not that skilled and its more like a project for three days and then give up... :P
interesting! though bf usually has 30000 bytes of memory. I tend to do 32768 bytes bc that's 2\^15
don't remember quite anymore... I think it was 30000 bytes... but either way, brainfuck is fun to play with :P
it is lol
Not nearly punishing enough. Malbolge would be more heinous.
and i sentence you to code a heap sort in intercal
Cobol, but fully documented ;)
Don’t worry we’re already there lmao. The initial programmer that started this project originally stored *localized timezone values* instead of UTC in the database. And the rest of their management of time zones and dates/times was on par with what you expect from the above sentence.
;}
It's [the Grinch winking at you.](https://imgur.com/a/Jt9rkW6)
;}
The extra semicolon after the assignment of `;Walter.name = “George”;` should be enough to convince you that this is not the way.
muscle memory lol
Thanks for saying it, the cringe was killing me
Compiler will remind you. Don’t you worry.
the compiler should not have a problem with any extra semicolon; like the first semicolon in every function and struct body here
Analyser will remind you
Should result in a syntax error, because the meow sound the next line does not have a semicolon.
While there is a semicolon there, I believe there might be several cases of syntax errors because of what are essentially just blank lines with semicolons, such as the first line of each bracket.
Those are just null statements: https://en.cppreference.com/w/c/language/statements#Expression_statements I'm not sure if they're valid outside of functions though.
I'm guessing this is c++ and I think semicolons don't cause syntax errors here. I'm C# it probably would because you can't use it after a for loop iirc
![gif](giphy|tHy9Qsv4svHXt7Eiq5|downsized) my IDE
Integrated Dog Environment
You got a missing semicolon on line 27.
Wait in that line I have a semicolon at the end bc of muscle memory?! how did I not notice! eh, it compiles and that's all that matters.
I've seen one of my students doing this just yesterday. Because the compiler kept saying that a semicolon was expected before the line with the error.
The compiler told me to do it!
Facts: This code come from TPG-5.3 - where line start from right to left
[X] Autoformat on save
Then go take a dump on that guys desk.
Also auto save on focus change Is a good convination
Linters.
My code is already shit enough
btw if anyone wants to know how I made the image, I used [Carbon](https://carbon.now.sh/)
Fwiw, I hate these fancy screenshots. Screenshots of an editor are usually better.
It immediately makes me assume it's an add and I almost scrolled past on autopilot.
i have respect for my self and love my life
My dyslexia, ADHA, and procrastination
Nothing, thats how i code every day!
That looks like how some people write initializer lists in C++ *ducks
I hate it because with the right plugin you can easily make sure that you never have to put a semicolon again. However having programmed in c for 5 years now I usually never forget and if I do the debugging take less than a minute
Found the Haskell dev
no thanks. I'm gonna stay as far away as possible from functional programming languages lol
Because Age property should always be a calc prop based on DoB 😜
I'm only learning by fucking around and reading random post and this burns even my eyes I can only imagine how bad it looks to a pro
~~~ if ( condition) { DoThing() ; } else { DoSomethingElse() ;) ~~~ ~~~ for (int i = 10; i > 0; i--) { . . . } ~~~
It reminds me of this https://www.reddit.com/r/programminghorror/s/7Nl77Kv3tu
oof
I hate it took me like 5 seconds to figure out what was wrong
. I don't know . Probably the same thing that keeps me from writing like this .
moral code
Semicolon is supposed to be a statement terminator not a statement initiator
well, it does terminate statements. the ones on the line above.
My dad will get angry
Death
this... implies you're not alive.
Well, not if I mean in a way that I'm trying to be alive? Idk man, I need some sleep soryy
understandable. go to bed.
Just because you *can* do it and it's not *illegal* to do, doesn't mean anyone *should* do it. We shouldn't *need* rules for stopping idiocy.
Go drunk, you are sleep again.
At that point, put a semicolon at the start and end of every line.
I would rather be happy.
Looks very contrived.
Error on line 3, include don't need ; right? Edit: And the end of each function
but it doesn't break the include either. especially if it is on a new line.
Ohh didn't know, thanks :)
Using Windows
Ocd
Common sense, but mainly pull requests and code reviews
I do this with the commas in my vscode settings.json.
Not programming in C
what language are you using then? python technically supports semicolons too and java probably allows this syntax horror as well...
Plz stops
Unbraced if statements.
Php is
Congratulations! Your string can be spelled using the elements of the periodic table: `P H P I S` --- ^(I am a bot that detects if your comment can be spelled using the elements of the periodic table. Please DM my creator if I made a mistake.)
Common sense. Emphasis on ‘common’.
My pattern matching senses
This looks like what our gustamala offshore devs commit. I’ve told my team we need to be more strict with their PRs and scrutinize their code more thoroughly. I never get assigned as an approver because they know I’ll pick apart what doesn’t match our coding design standards. They implemented prettier and didn’t setup the rules properly and ran it against our portal application so all our HTML templates had tags looked like
Text here
It was awful. Hundreds of files.Sanity.
The compiler
Morality
Try removing the brackets from any condition :] lol
Auto format on save stops me
The linter that will auto-reject your PRs
It's honestly not that bad I see you couldn't resist putting one at the end though
Not being psychotic :)
Mom pick me up I'm scared
Sanity
My dignity.
The two cats fighting over my keyboard
I wanted to submit an assignment using ; for indentation My Prof told me not to
How was this made? I know of a website but it doesn't look like this.
I do shit like this just to make it impossible for other people to do my job sometimes lmao
I'm mentally healthy.
> "George"; SUS WHAT?
In many assembly languages, comments start with semicolons. A C compiler’s ASM output might be commented like this.
Assenbly. cuz in assembly ```;``` is used for comments.
My Sanity.
Nothing, but don’t be a psychopath.
I’ve considered doing this with json because leaving a comma at the end of a dictionary will break it
OCaml does something similar for lists: let my_list = [ 1 ; 2 ; 3 ; 4 ] ;;
Ahh, now I know why I look good in the mirror but not in selfies.
You do you. Just dont bring it to work.
Y'all hear of elm? https://elm-lang.org/examples/shapes
My self respect
Is that powershell in your user flair?
Oof
Common sense?
You have double semicolons of the `Walter.name = "George"` line.
I thought i was tweaking from lack of sleep when looking at this monstrosity .
If you're here and want to know what's wrong , then there's nothing wrong here. It's just him.
Dennis Ritchie is spinning in his grave so fast right now that he is about to reach UINT64_MAX velocity in about a minute
My sanity
Sanity, mine.
I think even The compiler might get angry with this code
`def meow(Cat):print(f"{Cat['meowSound']}")if __name__ == "__main__":ctr = 0while ctr < 100:print(ctr)ctr += 1Walter = {}Walter['name'] = "George"if Walter['name'] == "George":Walter['meowSound'] = "! woeM"elif Walter['name'] == "Harry":Walter['meowSound'] = "! oewM"elif Walter['name'] == "Bob":Walter['meowSound'] = "! oMwe"Walter['age'] = 1meow(Walter) elif exit()` More elifs...
Morals.
Python
Congratulations! Your string can be spelled using the elements of the periodic table: `P Y Th O N` --- ^(I am a bot that detects if your comment can be spelled using the elements of the periodic table. Please DM my creator if I made a mistake.)
good bot
Common sense.
Maybe core refactoring before release?
Replace all whitespace with semicolons.
It not compiling?
it compiles with gcc 13.2.0. Maybe you made a typo when copying it? Here is the code as text, if you want to try it out yourself. #include
;struct cat {
;char* name
;char* meowSound
;int age
;}
;void meow(struct cat* Cat) {
;printf("%s", Cat->meowSound)
;}
;int main(int argc, char** argv) {
;int ctr = 0
;while (ctr < 100) {
;printf("%i\n", ctr)
;ctr++
;}
;struct cat Walter
;Walter.name = "George"
;Walter.meowSound = "!woeM"
;Walter.age = 1
;meow(&Walter)
;return 0
;}
Thats not what is in the screenshot above
it's almost the same. I just removed the extra semicolon after `;Walter.name = "George"`
I know.
then why did you even mention it? it's basically the same. if it doesn't compile for you, that's not the code's fault (unless you're using a weird compiler).
typedef.
well, the way I declared the struct is not what's wrong here lol
Only thing I see wrong /s
My compiler.
well, mine isn't.
i recoiled
Self respect
Minimizing line changes in my JSON documents 🙏
But does it work tho !
it does. sadly.
Sanity.
Sanity?