0

I am stuck in week 1 lectures. Initially after watching the videos I was able to run the codes, 'make hello' and './hello.c', then after an update to the CS50 appliance the codes wouldn't run any longer. When I 'make hello', it says hello is up to date, when I run './hello.c', it says 'Permission Denied'. I removed the appliance from VMWare Player and re-installed, unfortunately for me the problem persisted. I even went as far as running it on a terminal in Oracle Enterprise Linux, I still have the same problem. I have tried several solutions I found on Google, all to no avail. This is the third year in a row I registered for CS50 and I definitely want to make it this year, please HELP!!!

1

Actually, you don't really have a problem. You just need a little instruction on a couple of nuances that you're tripping on.

First, make is saying up to date because the output of the compiler, file "hello", is current because hello.c has not been changed since the last time you ran "make hello". If you were to edit hello.c and make any changes, even adding a space or an extra blank line, or making and undoing a change, then make would run and it would build a new executable file called 'hello'. (Deleting the output file will let make run too.) BTW, later lessons will give more details on the workings of make.

Next, you're trying to execute the wrong file. The command

./hello.c

is trying to execute the source file. The proper way to run it is

./hello

This will run the executable program file. As for the appliance, put it all back the way it was. If necessary, remove completely and reinstall.

| improve this answer | |

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .