As you've probably guessed, I'm onto my very first "Hello World!" C++ program, which seems easy enough.
In Ubuntu, I've opened up the text editor and I've written the code and saved it as a .cpp which worked fine.
In the terminal, after taking it to the place where I saved my .cpp, I wrote:
g++ -Wall -W -Werror hello.cpp -o hello
It created a file in that folder, with no extension, which I guess is expected on Linux.
If I type "./hello" (without "s), it says Hello World! on my screen. Great.
Now the issue is that when I head over to the folder where hello is saved, double-clicking it won't do anything.
How can I change it in a way so that it won't need to be opened using the terminal, but rather simply by being double-clicked?
Thanks in advance, and I apologise for my noobiness. I guess we all start somewhere
In Ubuntu, I've opened up the text editor and I've written the code and saved it as a .cpp which worked fine.
In the terminal, after taking it to the place where I saved my .cpp, I wrote:
g++ -Wall -W -Werror hello.cpp -o hello
It created a file in that folder, with no extension, which I guess is expected on Linux.
If I type "./hello" (without "s), it says Hello World! on my screen. Great.
Now the issue is that when I head over to the folder where hello is saved, double-clicking it won't do anything.
How can I change it in a way so that it won't need to be opened using the terminal, but rather simply by being double-clicked?
Thanks in advance, and I apologise for my noobiness. I guess we all start somewhere