Guest User

Untitled

a guest
Jun 21st, 2018
69
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.28 KB | None | 0 0
  1. #include <stdio.h>
  2. #include <stdlib.h>
  3.  
  4. char* second_word(char text[] )
  5. {
  6. char *ptr = text;
  7. while(*ptr != ' ' && *ptr != ' ' && *ptr != 0)
  8. {
  9. ptr++;
  10. }
  11. return ++ptr;
  12. }
  13.  
  14. char text[] = "Hello World";
  15.  
  16. int main(int argc, char *argv[]) {
  17.  
  18. printf("%s" , second_word(text));
  19. return 0;
  20. }
Add Comment
Please, Sign In to add comment