C++ run error...

Confused++'s Avatar
Newbie Member
I know I'm posting this forum twice, but I lost my original post and I didn't know there was a "Linux" forum.
When I compile my program by typing...
g++ foo.cpp
...it compiles just fine and a little happy a.out file pops up. However, when I try to run the program...
I get an error message along the lines of...
a.out: Permission denied
I checked the permissions. They're normal: I can read, write, and execute; everyone else can read and execute; etc...
I have the same problem with Perl programs as well, but I found that when I type...
perl foo.pl
...that seems to fix the problem. I'm just concerned about C++. Do I need a package that may be corrupted? Thanks in advance.
shabbir's Avatar, Join Date: Jul 2004
Go4Expert Founder
You have posted it as an Article and so it went to Editorial review and your posts is moved into the forums. Duplicate of Can't run C++ programs!. Thread closed.