Advertisement
mario_mos

char1char2

Jul 24th, 2023
28
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.41 KB | None | 0 0
  1. #include <stdio.h>
  2. #include <math.h>
  3. #include <stdlib.h>
  4. #include <time.h>
  5. #include <string.h>
  6. int main()
  7. {
  8.  
  9.  
  10. char ch1 [10];
  11. strcat(ch1,"bonjour");
  12. char ch2 [10];
  13. strcat(ch2,"gilles");
  14.  
  15.  
  16. printf("1ere Valeur de strcmp(): %d\n", strcmp(ch1, ch2));
  17. strcat(ch1,ch2);
  18. strcat(ch2,ch1);
  19. printf("2eme Valeur de strcmp(): %d\n", strcmp(ch1, ch2));
  20.  
  21.  
  22.  
  23.  
  24.  
  25.  
  26. return 0;
  27. }
  28.  
  29.  
  30.  
  31.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement