#how can i fix this

7 messages · Page 1 of 1 (latest)

wheat marlinBOT
#

When your question is answered use !solved to mark the question as resolved.

Remember to ask specific questions, provide necessary details, and reduce your question to its simplest form. For tips on how to ask a good question run !howto ask.

long trail
#

sorry

#

ill repost

#
   int x = 5;

    int result;
    if (x > 10);

    if (x > 20);
        printf("hello");
        else
        printf("goodbye");
printf("%d", result);```
twilit oracle
#

In the future, always explain what the error is.
If it is failing to compile, give the error message of the compilation
If it compiles, but when you run it and it didn't do what you expect, tell us what you expected, and what the program outputted.

Anyway, don't put ; after an if statement
if (true); is equivalent to if (true) {}

long trail
#

!solved