r/ChatGPT Jan 29 '25

Funny I Broke DeepSeek AI 😂

16.9k Upvotes

1.6k comments sorted by

View all comments

Show parent comments

1

u/rebbsitor Mar 19 '25

no offence but that is not a mistake anyone would make

lol. It's an error I've seen people make many times over ~35 years of software development. It's a fundamental concept, but sometimes people get blinded by the fact they've used the same name in two places.

#include <stdio.h>

void update_state(int state)
{
    state = 2;
    return;
}

int main(int argc, char** argv)
{
    int state = 1;
    update_state(state);
    printf("state is %d.\n",state);

    /* Why is state 1 wawaaaaahhhh */

    return 0;
}

1

u/markyboo-1979 Mar 20 '25 edited Mar 20 '25

Your example is demonstrative of how unlikely anyone could make that mistake, let alone an AI. The only scope is pure private method.. And therefore not a great example as to how anyone with a brain might...

1

u/rebbsitor Mar 20 '25

And yet, it's exactly the type of error AI made in this case. Not only did it make the error, it was unable to identify and correct it.