Skip to content

Comment on Write a program that makes 2 + 2 = 5

Comments

How about the opposite? Make 2+3=4, here in C.

    add2And3(int *a, int *b)
    {
       *a = 3;
       *b = 2;
       printf("%d", *a + *b);  //4
    }
    void main()
    {
       int storage;
       add2And3(&storage, &storage);
    }
AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.