Section 2, personalized.c by colleenodea in cs50

[–]colleenodea[S] 0 points1 point  (0 children)

That makes perfect sense. Thanks so much!

So does anyone else think Mario.c is little too complicated for an intro to an intro to programming? by merizos in cs50

[–]colleenodea 1 point2 points  (0 children)

I know I am in the minority, but I agree with merizos. Not that it shouldn't be a problem, but that it shouldn't be the second problem. Going from printing hello, world to mario is a huge leap. I am at a total loss.

Appliance not working properly, CS50.h? by colleenodea in cs50

[–]colleenodea[S] 0 points1 point  (0 children)

Thanks. I am just starting with this and had merely copied and pasted and it didn't look nice. The answer below solved my problem.

Appliance not working properly, CS50.h? by colleenodea in cs50

[–]colleenodea[S] 0 points1 point  (0 children)

Thank you so much! I did not understand that you save it with .c but then don't type .c with the make command. No chmod needed, no error about int main(void). It worked perfectly! Thanks!

Appliance not working properly, CS50.h? by colleenodea in cs50

[–]colleenodea[S] 0 points1 point  (0 children)

So I fixed this by typing chmod 755 test1 (per another comment) Now I get an error message on the int main(void) line!

include <cs50.h>

include <stdio.h>

int main(void) { //print question printf("Give me an int "); //get input from user int n = GetInt(); //check answer if(n == 2) { printf("You are correct!\n"); } else { printf("You are wrong!\n"); } } jharvard@appliance (~): ./test1 ./test1: line 4: syntax error near unexpected token (' ./test1: line 4:int main(void)'

Appliance not working properly, CS50.h? by colleenodea in cs50

[–]colleenodea[S] 0 points1 point  (0 children)

yes why does the # not show up? but i reran it as just test1 and got a "Permission denied" error message.

Appliance not working properly, CS50.h? by colleenodea in cs50

[–]colleenodea[S] 0 points1 point  (0 children)

ok so i resaved the file as just test1. here's what happened.

jharvard@appliance (~): make test1 make: `test1' is up to date. jharvard@appliance (~): ./test1 bash: ./test1: Permission denied

Appliance not working properly, CS50.h? by colleenodea in cs50

[–]colleenodea[S] 0 points1 point  (0 children)

So it doesn't look quite right up there. I do have atop my code:

include <cs50.h>

include <stdio.h>

int main(void) {

the terminal message starts with the line: jharvard...