Installing “C” on Ubuntu 18.04 LTS [duplicate]Can't run my hello world in C“cannot find -lmpi*” when compiling openmpi codeSony flash tools .tar installation on ubuntu 18.04associating file types with program in ubuntu 18.04

In-body neutral density (ND) filters?

SMD ceramic capacitor 0805 vs 1206

Phrase/Word-pair for a variant of master-slave relationship

Did Ohio pass a law granting students the right to give scientifically wrong answers consistent with their religious beliefs?

What definition takes up more memory, def or chardef (considering def contains a single character)?

What does shimmy in nose landing gear mean?

Why does rapeseed oil turn sticky but coconut oil doesn't?

Do monthly payments decrease on a mortgage later in the loan?

Arabia and the Middle Ages

Rsync: Are there any way to exclude multiples files and directory shortly?

Does 5e have a Manual of the Planes?

Was equal temperament caused by the invention of the piano, or was it inevitable?

Can a website incur liability for linking to a funding campaign for a lawsuit against it?

What is the "two-drive trick" that can read Amiga disks on a PC?

If you discard Immortal Phoenix, does it return to your hand?

Why are superuser permissions needed to acess /data partition?

Sort and Table a Sentence by Word Lengths

Why has no one requested the tape of the Trump/Ukraine call?

Getting into new PhD after failing comps

Is Scrum actually suitable for all kinds of projects?

Why are the rain clouds darker?

When Using Throne room on a Throne room do you need two more action cards already in hand?

Are we sinners because we sin or do we sin because we are sinners?

What kinds of sanctions would be applied if you wrongly invoked the Fifth Amendment?



Installing “C” on Ubuntu 18.04 LTS [duplicate]


Can't run my hello world in C“cannot find -lmpi*” when compiling openmpi codeSony flash tools .tar installation on ubuntu 18.04associating file types with program in ubuntu 18.04






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty
margin-bottom:0;









0



















This question already has an answer here:



  • Can't run my hello world in C

    2 answers



I typed the "Hello, World" program in the Ubuntu text editor.

The file, 'hello' was saved to the documents folder, which I verified, is there.



However, the "c" compiler, version 7.4.0-1, cannot find 'hello.'

Moreover, the program 'find' cannot find it either.

I would appreciate any help you can give me.










share|improve this question

















marked as duplicate by karel, Kulfy, Eliah Kagan, Kristopher Ives, cmak.fr Sep 13 at 6:55


This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.














  • 1





    Save it to your Home directory. Otherwise you'll need to provide path to this file.

    – Pilot6
    Aug 26 at 17:36






  • 1





    Would you post the commands you use, and the ls of you Documents/ directory?

    – guillermo chamorro
    Aug 26 at 17:45











  • @Pilot6 Why is that? I can compile a file in a subdir without a full path.

    – guillermo chamorro
    Aug 26 at 17:48











  • Anyway you need some path. You can't compile file hello in your Documents by running gcc hello.

    – Pilot6
    Aug 26 at 17:50











  • @Pilot6 But I can do it?

    – guillermo chamorro
    Aug 26 at 18:18

















0



















This question already has an answer here:



  • Can't run my hello world in C

    2 answers



I typed the "Hello, World" program in the Ubuntu text editor.

The file, 'hello' was saved to the documents folder, which I verified, is there.



However, the "c" compiler, version 7.4.0-1, cannot find 'hello.'

Moreover, the program 'find' cannot find it either.

I would appreciate any help you can give me.










share|improve this question

















marked as duplicate by karel, Kulfy, Eliah Kagan, Kristopher Ives, cmak.fr Sep 13 at 6:55


This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.














  • 1





    Save it to your Home directory. Otherwise you'll need to provide path to this file.

    – Pilot6
    Aug 26 at 17:36






  • 1





    Would you post the commands you use, and the ls of you Documents/ directory?

    – guillermo chamorro
    Aug 26 at 17:45











  • @Pilot6 Why is that? I can compile a file in a subdir without a full path.

    – guillermo chamorro
    Aug 26 at 17:48











  • Anyway you need some path. You can't compile file hello in your Documents by running gcc hello.

    – Pilot6
    Aug 26 at 17:50











  • @Pilot6 But I can do it?

    – guillermo chamorro
    Aug 26 at 18:18













0













0









0









This question already has an answer here:



  • Can't run my hello world in C

    2 answers



I typed the "Hello, World" program in the Ubuntu text editor.

The file, 'hello' was saved to the documents folder, which I verified, is there.



However, the "c" compiler, version 7.4.0-1, cannot find 'hello.'

Moreover, the program 'find' cannot find it either.

I would appreciate any help you can give me.










share|improve this question

















This question already has an answer here:



  • Can't run my hello world in C

    2 answers



I typed the "Hello, World" program in the Ubuntu text editor.

The file, 'hello' was saved to the documents folder, which I verified, is there.



However, the "c" compiler, version 7.4.0-1, cannot find 'hello.'

Moreover, the program 'find' cannot find it either.

I would appreciate any help you can give me.





This question already has an answer here:



  • Can't run my hello world in C

    2 answers







18.04 compiling






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Aug 26 at 20:16









Thomas Ward

52.7k24 gold badges132 silver badges190 bronze badges




52.7k24 gold badges132 silver badges190 bronze badges










asked Aug 26 at 17:34









O. Donn GraceO. Donn Grace

1




1





marked as duplicate by karel, Kulfy, Eliah Kagan, Kristopher Ives, cmak.fr Sep 13 at 6:55


This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.











marked as duplicate by karel, Kulfy, Eliah Kagan, Kristopher Ives, cmak.fr Sep 13 at 6:55


This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.









marked as duplicate by karel, Kulfy, Eliah Kagan, Kristopher Ives, cmak.fr Sep 13 at 6:55


This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.









  • 1





    Save it to your Home directory. Otherwise you'll need to provide path to this file.

    – Pilot6
    Aug 26 at 17:36






  • 1





    Would you post the commands you use, and the ls of you Documents/ directory?

    – guillermo chamorro
    Aug 26 at 17:45











  • @Pilot6 Why is that? I can compile a file in a subdir without a full path.

    – guillermo chamorro
    Aug 26 at 17:48











  • Anyway you need some path. You can't compile file hello in your Documents by running gcc hello.

    – Pilot6
    Aug 26 at 17:50











  • @Pilot6 But I can do it?

    – guillermo chamorro
    Aug 26 at 18:18












  • 1





    Save it to your Home directory. Otherwise you'll need to provide path to this file.

    – Pilot6
    Aug 26 at 17:36






  • 1





    Would you post the commands you use, and the ls of you Documents/ directory?

    – guillermo chamorro
    Aug 26 at 17:45











  • @Pilot6 Why is that? I can compile a file in a subdir without a full path.

    – guillermo chamorro
    Aug 26 at 17:48











  • Anyway you need some path. You can't compile file hello in your Documents by running gcc hello.

    – Pilot6
    Aug 26 at 17:50











  • @Pilot6 But I can do it?

    – guillermo chamorro
    Aug 26 at 18:18







1




1





Save it to your Home directory. Otherwise you'll need to provide path to this file.

– Pilot6
Aug 26 at 17:36





Save it to your Home directory. Otherwise you'll need to provide path to this file.

– Pilot6
Aug 26 at 17:36




1




1





Would you post the commands you use, and the ls of you Documents/ directory?

– guillermo chamorro
Aug 26 at 17:45





Would you post the commands you use, and the ls of you Documents/ directory?

– guillermo chamorro
Aug 26 at 17:45













@Pilot6 Why is that? I can compile a file in a subdir without a full path.

– guillermo chamorro
Aug 26 at 17:48





@Pilot6 Why is that? I can compile a file in a subdir without a full path.

– guillermo chamorro
Aug 26 at 17:48













Anyway you need some path. You can't compile file hello in your Documents by running gcc hello.

– Pilot6
Aug 26 at 17:50





Anyway you need some path. You can't compile file hello in your Documents by running gcc hello.

– Pilot6
Aug 26 at 17:50













@Pilot6 But I can do it?

– guillermo chamorro
Aug 26 at 18:18





@Pilot6 But I can do it?

– guillermo chamorro
Aug 26 at 18:18










1 Answer
1






active

oldest

votes


















3



















Welcome to Ask Ubuntu!



Make sure you are in the same directory in terminal as is your file hello.c. Type cd /path/to/your_folder/ in terminal to go to it.



Then, gcc hello.c -o helloout should compile it to the output file helloout. To execute the compiled code, type ./helloout.



Note: If I left the code file hello without the .c extension, gcc says



file not recognized: Unrecognized file format


Follows the example I tested (hello.c).



#include <stdio.h>

int main()
printf("Hello, Worldn");
return 0;






share|improve this answer

































    1 Answer
    1






    active

    oldest

    votes








    1 Answer
    1






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    3



















    Welcome to Ask Ubuntu!



    Make sure you are in the same directory in terminal as is your file hello.c. Type cd /path/to/your_folder/ in terminal to go to it.



    Then, gcc hello.c -o helloout should compile it to the output file helloout. To execute the compiled code, type ./helloout.



    Note: If I left the code file hello without the .c extension, gcc says



    file not recognized: Unrecognized file format


    Follows the example I tested (hello.c).



    #include <stdio.h>

    int main()
    printf("Hello, Worldn");
    return 0;






    share|improve this answer






























      3



















      Welcome to Ask Ubuntu!



      Make sure you are in the same directory in terminal as is your file hello.c. Type cd /path/to/your_folder/ in terminal to go to it.



      Then, gcc hello.c -o helloout should compile it to the output file helloout. To execute the compiled code, type ./helloout.



      Note: If I left the code file hello without the .c extension, gcc says



      file not recognized: Unrecognized file format


      Follows the example I tested (hello.c).



      #include <stdio.h>

      int main()
      printf("Hello, Worldn");
      return 0;






      share|improve this answer




























        3















        3











        3









        Welcome to Ask Ubuntu!



        Make sure you are in the same directory in terminal as is your file hello.c. Type cd /path/to/your_folder/ in terminal to go to it.



        Then, gcc hello.c -o helloout should compile it to the output file helloout. To execute the compiled code, type ./helloout.



        Note: If I left the code file hello without the .c extension, gcc says



        file not recognized: Unrecognized file format


        Follows the example I tested (hello.c).



        #include <stdio.h>

        int main()
        printf("Hello, Worldn");
        return 0;






        share|improve this answer














        Welcome to Ask Ubuntu!



        Make sure you are in the same directory in terminal as is your file hello.c. Type cd /path/to/your_folder/ in terminal to go to it.



        Then, gcc hello.c -o helloout should compile it to the output file helloout. To execute the compiled code, type ./helloout.



        Note: If I left the code file hello without the .c extension, gcc says



        file not recognized: Unrecognized file format


        Follows the example I tested (hello.c).



        #include <stdio.h>

        int main()
        printf("Hello, Worldn");
        return 0;







        share|improve this answer













        share|improve this answer




        share|improve this answer










        answered Aug 26 at 17:54









        Rodolfo FRRodolfo FR

        463 bronze badges




        463 bronze badges
















            Popular posts from this blog

            Tamil (spriik) Luke uk diar | Nawigatjuun

            Align equal signs while including text over equalitiesAMS align: left aligned text/math plus multicolumn alignmentMultiple alignmentsAligning equations in multiple placesNumbering and aligning an equation with multiple columnsHow to align one equation with another multline equationUsing \ in environments inside the begintabularxNumber equations and preserving alignment of equal signsHow can I align equations to the left and to the right?Double equation alignment problem within align enviromentAligned within align: Why are they right-aligned?

            Training a classifier when some of the features are unknownWhy does Gradient Boosting regression predict negative values when there are no negative y-values in my training set?How to improve an existing (trained) classifier?What is effect when I set up some self defined predisctor variables?Why Matlab neural network classification returns decimal values on prediction dataset?Fitting and transforming text data in training, testing, and validation setsHow to quantify the performance of the classifier (multi-class SVM) using the test data?How do I control for some patients providing multiple samples in my training data?Training and Test setTraining a convolutional neural network for image denoising in MatlabShouldn't an autoencoder with #(neurons in hidden layer) = #(neurons in input layer) be “perfect”?