this post was submitted on 26 Nov 2023
707 points (89.2% liked)

Programmer Humor

19821 readers
880 users here now

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

founded 2 years ago
MODERATORS
 
you are viewing a single comment's thread
view the rest of the comments
[–] youCanCallMeDragon@lemmy.world 4 points 1 year ago (3 children)

I wonder if chat GPT can add comments

[–] glibg10b@lemmy.ml 29 points 1 year ago* (last edited 1 year ago) (2 children)
// Greetings, intrepid explorer, to the magnum opus of verbosity – the exhaustive elucidation
// of the venerable "Hello, World!" program in the illustrious realm of C++.

// Our inaugural act involves the summoning of external powers through the sacred rite of inclusion.
// The venerable  library is invoked, opening the gateway to input and output sorcery.
#include 

// Brace yourself, noble adventurer, for the initiation of our journey transpires within the sanctum
// of the 'main' function – the veritable heart and soul of our C++ odyssey.
int main() {
    // Let us forge a pact with the realm of 'std', alleviating the syntactic tribulations
    // through the divine power of the 'using' declaration. Behold the namespace, a sanctuary
    // where the gods of C++ convene, rendering our code free from the shackles of verbosity.
    using namespace std;

    // As we stand on the precipice of expression, the 'cout' oracle emerges.
    // This venerable entity, an emissary of the standard output stream, awaits our command.
    // With the '<<' conjuration, we channel the essence of our proclamation, "Hello, World!",
    // and cast it into the void of the console, where it shall resonate for eternity.
    cout << "Hello, World!" << endl;

    // The denouement approaches, where our protagonist, the 'main' function,
    // bestows upon the cosmic arbiter – the operating system – a token of acknowledgment.
    // The triumphant 'return 0' is a symphony of numerical reverence, echoing
    // the harmony of a flawless performance in the grand opera of computational artistry.
    return 0;
}
[–] GissaMittJobb@lemmy.ml 14 points 1 year ago

10/10 literate programming points

[–] Beanie@programming.dev 7 points 1 year ago

Ah yes, #include\n. The magical include that simply copy-pastes the entirety of libc's headers into your source file.

[–] charliespider@lemmy.world 9 points 1 year ago* (last edited 1 year ago) (1 children)

Chat GPT is great at writing comments. Usually writes better comments than I do. I'm using copilot which uses Chat GPT so it's also repo aware.

[–] Landless2029@lemmy.world 1 points 1 year ago

I second github copilot

[–] Landless2029@lemmy.world 3 points 1 year ago

Try github copilot I've canceled my chatgpt for it.

Now I start scripting by doing all my comments. Essentially make a outline like I'm writing a paper.

Copilot suggests the code that matches my comments.

I script legit 3x~4x faster now with full comments. It's amazing.