/in/foo.cc:1:1: error: 'include' does not name a type
include <stdio.h>
^~~~~~~
/in/foo.cc: In function 'int main()':
/in/foo.cc:9:44: error: 'scanf' was not declared in this scope
scanf("%d%d%lf%lf%lf",&n,&m,&d,&first,&last);
^
/in/foo.cc:11:38: error: 'printf' was not declared in this scope
printf("%.3lf\n", m==1 ? first : last);
^
/in/foo.cc:13:1: error: 'a' was not declared in this scope
a[n][0] = 1;
^
/in/foo.cc:21:54: error: 'printf' was not declared in this scope
printf("%.3lf\n",a[m][0]*last + a[m][1]*t + a[m][2]*d);
^