20120113

How to use fork in C++

//========================
//Program in cpp for "fork",  fork2.c
//========================
#include<iostream>
using namespace std;
extern char **environ;
int main(int argc,char argv[])
{
cout<<"Hello World";
cout<<"First argument is \n "<<argv[1];
cout<<"Environment is \n "<<environ[0];
cout<<"Environment is \n "<<environ[1];
return 0;
}

1 comment:

  1. How to use fork in C++

    Program in cpp for "fork",
    How to use fork in C++

    Program in cpp for "fork",
    How to use fork in C++

    Program in cpp for "fork",
    How to use fork in C++

    Program in cpp for "fork",
    How to use fork in C++

    Program in cpp for "fork",
    How to use fork in C++

    Program in cpp for "fork",
    How to use fork in C++

    Program in cpp for "fork",

    ReplyDelete