6 main (int argc
, char *argv
[])
8 int rank
, size
, length
;
11 MPI_Init (&argc
, &argv
);
12 MPI_Comm_rank (MPI_COMM_WORLD
, &rank
);
13 MPI_Comm_size (MPI_COMM_WORLD
, &size
);
14 MPI_Get_processor_name (name
, &length
);
16 printf ("%s: hello world from process %d of %d\n", name
, rank
, size
);