home *** CD-ROM | disk | FTP | other *** search
/ C Programming Starter Kit 2.0 / SamsPublishing-CProgrammingStarterKit-v2.0-Win31.iso / tyc / list1714.c < prev    next >
C/C++ Source or Header  |  1993-10-16  |  431b  |  15 lines

  1.  /* strrev(), strset(), and strnset(). */
  2.  #include <stdio.h>
  3.  #include <string.h>
  4.  
  5.  char str[] = "This is the test string.";
  6.  
  7.  main()
  8.  {
  9.      printf("\nThe original string: %s", str);
  10.      printf("\nCalling strrev(): %s", strrev(str));
  11.      printf("\nCalling strrev() again: %s", strrev(str));
  12.      printf("\nCalling strnset(): %s", strnset(str, '!', 5));
  13.      printf("\nCalling strset(): %s", strset(str, '!'));
  14.  }
  15.