rambo189619

Untitled

Aug 22nd, 2011
236
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.45 KB | None | 0 0
  1. #include<stdio.h>
  2. #include<conio.h>
  3. #define PI 3.14
  4. main()
  5. {
  6.   clrscr();
  7.   printf(" Area del circulo (1) , Longitud del circulo (2) /n ");
  8.   scanf("%d",&opcion);
  9.   printf("Introduzca el radio " );
  10.   scanf("%d,&radio);
  11.  int resultado1, resultado2;
  12.  
  13.  switch(opcion)
  14.  {
  15.   case 1:
  16.    resultado1 =2*pi*r;
  17.    printf("%f",resutlado1);
  18.    
  19.    break;
  20.  
  21.   case 2:
  22.  
  23.    resultado2 =pi*pi*r;
  24.     printf("%f",resultado2);
  25. }
  26.  
  27. getch();
Advertisement
Add Comment
Please, Sign In to add comment