nikolas_serafini

Lista 4 - Exercício 30

Jun 24th, 2013
37
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.34 KB | None | 0 0
  1. #include <stdio.h>
  2. #include <string.h>
  3.  
  4. int main()
  5. {  
  6.     char firstWord[50],secondWord[50];
  7.  
  8.     printf("Entre com a primeira palavra :\n");
  9.     gets(firstWord);
  10.     printf("Entre com a segunda palavra :\n");
  11.     gets(secondWord);
  12.  
  13.     strcat(firstWord,"\n");
  14.     strcat(firstWord,secondWord);
  15.     puts(firstWord);
  16.  
  17.     return 0;
  18. }
Advertisement
Add Comment
Please, Sign In to add comment