I just thought of something... someone else just asked a similar question. Did you make sure to print a newline (endl, or "\n") after printing "Hello" from your program? Output doesn't always go to the screen unless you send a newline.
i.e.: Code:
#include <iostream> ./test |
My source code is:
/*Filename: test.c make command: gcc -o test test.c */ #include <stdio.h> int main() { printf("Hello\n"); return 0; } Pretty simple and includes newline. It always works with "./test" but not with "test" Kevin, I'm not getting any error messages and it just returns to prompt when I run "test". The whole path is: .:.:.:/bin/:/usr/bin:/usr/bin/X11:/usr/local/bin:/usr/bin:/usr/X11R6/bin:/home/XL/bin:/home/XL/bin Thank you so much! |
AhA!!!!!!!!!!!!!
"test" is a unix command. Try calling it something else like "foo" or "blah" |
Kevin, you are so right!!!!! Many thanks. ( I should remember I encountered the same problem in UNIX. :p )
|
All times are GMT -5. The time now is 04:04 PM. |