1 /* -*- Mode: C; c-basic-offset:4 ; -*- */ 2 /* 3 * (C) 2001 by Argonne National Laboratory. 4 * See COPYRIGHT in top-level directory. 5 */ 6 7 #include <stdio.h> 8 #include "mpi.h" 9 main(int argc,char * argv[])10int main( int argc, char *argv[] ) 11 { 12 int rank; 13 int size; 14 15 MPI_Init( 0, 0 ); 16 MPI_Comm_rank(MPI_COMM_WORLD, &rank); 17 MPI_Comm_size(MPI_COMM_WORLD, &size); 18 printf( "Hello world from process %d of %d\n", rank, size ); 19 MPI_Finalize(); 20 return 0; 21 } 22