FranciscoSoccol

Lista 09 - Exercicio 03

Sep 8th, 2013
57
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.37 KB | None | 0 0
  1. #include<stdio.h>
  2. #include<stdlib.h>
  3.  
  4. int main(int argc,char *argv[])
  5. {
  6.     int i;
  7.     char vet[][15]={"Janeiro","Fevereiro","Marco","Abril","Maio","Junho","Julho","Agosto","Setembro","Outubro","Novembro","Dezembro"};
  8.     for(i=0;i<12;i++)
  9.         if(atoi(*(argv+2))==i+1)
  10.             printf("%s de %s de %d",*(argv+1),vet[i],atoi(*(argv+3))+2000);
  11.     return 0;
  12. }
Advertisement
Add Comment
Please, Sign In to add comment