I'm trying to learn how to get started learning to do C++ coding on Ubuntu. I created a file called text.cpp with the following contents:
#include <stdio.h>
int main ()
{
printf("Hello World!");
}
I compiled it using the following line:
gcc test.c -o mytest
However, when I run ./mytest the string "Hello World!" shows up in front of the command prompt like this.
Hello World!mbishop@ubuntu:~bin$
Why is this happening and how can I get it to print after the command prompt. For example, like when you type echo "Hello Wolrd!".