Welcome, Guest. Please login or register.

Author Topic: Simple C programming question.  (Read 1976 times)

Description:

0 Members and 1 Guest are viewing this topic.

Offline elendilTopic starter

  • Sr. Member
  • ****
  • Join Date: Nov 2002
  • Posts: 324
    • Show all replies
    • http://www.idiot.fnuck.dk
Simple C programming question.
« on: February 25, 2003, 11:50:26 AM »
Mjallow.

I was just wondering if it is possible to easily execute programs within a C program.

What I mean is that I remember arexx had a command (forgot the name) that would do:
command-name c:wait 10, for example, running the wait program.

I could use that functionality, at least, though you probably shake your heads at me :)

Sincerely,

-Kenneth Straarup.
 

Offline elendilTopic starter

  • Sr. Member
  • ****
  • Join Date: Nov 2002
  • Posts: 324
    • Show all replies
    • http://www.idiot.fnuck.dk
Re: Simple C programming question.
« Reply #1 on: February 25, 2003, 11:58:16 AM »
Also what am I to do with the a.out file gcc produces when I type gcc filename? I am lousy at this, I know, I am used to java and lpc without linkers and makefiles and what-not I have on clue about :)

Sincerely,

-Kenneth Straarup.

EDIT: I just noticed I posted this in software discussion or something. I am not fully into this, I just his post new thread while reading another. Sorry for any inconvenience.
 

Offline elendilTopic starter

  • Sr. Member
  • ****
  • Join Date: Nov 2002
  • Posts: 324
    • Show all replies
    • http://www.idiot.fnuck.dk
Re: Simple C programming question.
« Reply #2 on: February 25, 2003, 12:14:40 PM »
Hey!

You were right. a.out was my compiled program. I just thought I remembered that stormC generated an a.out file AND a file to be executed, but I am probably wrong (it was a long time ago).

I will go try that System-thing right away. Thank you for your help.

Sincerely,

-Kenneth Straarup.
 

Offline elendilTopic starter

  • Sr. Member
  • ****
  • Join Date: Nov 2002
  • Posts: 324
    • Show all replies
    • http://www.idiot.fnuck.dk
Re: Simple C programming question.
« Reply #3 on: February 25, 2003, 12:25:15 PM »
And as you promised the system() function worked super as well.

Even though I forgot the include, but I suppose gcc included it for me then.

Sincerely,

-Kenneth Straarup.
 

Offline elendilTopic starter

  • Sr. Member
  • ****
  • Join Date: Nov 2002
  • Posts: 324
    • Show all replies
    • http://www.idiot.fnuck.dk
Re: Simple C programming question.
« Reply #4 on: February 26, 2003, 08:16:20 AM »
Roger that and thanks again.

Sincerely,

-Kenneth Straarup