ProgIng - Programación en Ingeniería
Loading...
Searching...
No Matches
Ejemplo032.c
Go to the documentation of this file.
1#include <stdio.h>
2#include <stdlib.h>
3
4int main(int argc, char *argv[])
5{
6 int i;
7 float pi;
8 if(argc>1)
9 {
10 for(i=1, pi=0; i<argc; i++)
11 pi+=atof(argv[i]);
12 printf("La suma es %f\n", pi);
13 return 0;
14 }
15 else
16 return 1;
17}
int main(void)
Definition Ejemplo_035.c:15