/* ** Lathe Program */ #include float rot = 180.0; float x[35][35], y[35][35], z[35][35]; float ix[35][1], iy[35][1]; int first_end, second_end, npolys=4, npts=4; float sin(), cos(); FILE *fopen(), *fp; main() { int verts, polys, i; float xx, yy; char filename[64]; input_vali("Number of Points ? ", &npts); for (i = 0; i - ",prompt,*value); scanf("%d",&val); if (val != -1) *value = val; scanf("%c", &character); /* eat up c/r, why though? */ } input_valf(prompt,value) float *value; char prompt[]; { char character; float val; printf("%s <%f> - ",prompt,*value); scanf("%lf",&val); if (val != -1) *value = val; scanf("%c", &character); /* eat up c/r, why though? */ } input_string(prompt, string) char prompt[]; char *string[]; { char character; char work_string[64]; int cnt = 0; character = 1; printf("%s", prompt); while (character != NULL) { scanf("%c", &character); if (character == '\n') character = NULL; work_string[cnt] = character; cnt = cnt + 1; } strcpy(string, &work_string); /* string is already pointer */ }