#include <stdio.h> #include <mpc.h> void init_vector(int n, double (*vec)[n]) { static double base=1.0; int i; for(i=0; i<n; i++) (*vec)[i] = base; base++; } int [*]main(int [host]argc, char *[host]argv[]) { [host]: { int n; n = atoi(argv[1]); if(n<=0) printf("Wrong input: n = %d\n", n); else { double v1[n], v2[n]; init_vector(n, &v1); init_vector(n, &v2); printf("Dot product of the vectors is equal to %g\n", [+](v1[]*v2[])); } } }