#include <iostream>
#include <sys/types.h>
#include <unistd.h>
#include <stdio.h>

using namespace std;

int main()
{

    pid_t pid, ppid;
    pid = getpid();
    ppid = getppid();


    cout << "pid" <<pid<< endl;
    cout << "ppid" <<ppid << endl;
    return 0;
}

Logo

北京人形旗下天工造物具身智能开源社区,聚焦具身天工与慧思开物两大平台

更多推荐