Thread: Other Newbee's might like to know this too

  1. #1
    Registered User
    Join Date
    Jul 2014
    Location
    Central Arizona
    Posts
    61

    Other Newbee's might like to know this too

    When I input code into codeblocks and then compile it. It makes 3 files. One holds the code for later us and has a. cpp extension.

    Can someone tell us what the other two files are for?
    I think one can be will run on other computers. I ran one if these file by double clicking on it and it only show for a millisecond and it was gone. Should I putt the cin.get () at the end of all my programs to stop it from closing? I don't need it with codeblocks.

  2. #2
    Registered User
    Join Date
    May 2009
    Posts
    4,183
    If you post the file extensions, someone might post an answer.
    "...a computer is a stupid machine with the ability to do incredibly smart things, while computer programmers are smart people with the ability to do incredibly stupid things. They are,in short, a perfect match.." Bill Bryson

  3. #3
    Registered User
    Join Date
    Oct 2014
    Posts
    5
    Quote Originally Posted by papagym177 View Post
    When I input code into codeblocks and then compile it. It makes 3 files. One holds the code for later us and has a. cpp extension.
    The .cpp file contains the c++ source code. The 2nd file .o is an object file that contains the object code (relocatable format machine code) !not directly executable!. The
    object file is used as input to the linker, which generates i.e. an executable. And that's what the third file is. An executable.

  4. #4
    Registered User antred's Avatar
    Join Date
    Apr 2012
    Location
    Germany
    Posts
    257
    Additionally, the precise nature of the output files may also depend on what compiler you're using. Code Block is not a compiler; it's an IDE that can work with almost any compiler under the sun.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. C program newbee
    By V17 in forum C Programming
    Replies: 10
    Last Post: 07-10-2011, 11:52 PM
  2. help a newbee
    By joker_tony in forum C Programming
    Replies: 2
    Last Post: 08-03-2009, 01:47 PM
  3. Newbee
    By Bio Hazord in forum C++ Programming
    Replies: 2
    Last Post: 10-22-2003, 07:08 PM
  4. Newbee
    By Dbug in forum C Programming
    Replies: 1
    Last Post: 12-14-2001, 12:45 AM
  5. Newbee question
    By d00-asu in forum Windows Programming
    Replies: 4
    Last Post: 08-31-2001, 03:32 AM