Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- SuperLib 3.50 - function crunch() http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 FUNCTION CRUNCH()

  Short:
  ------
  CRUNCH() Moves spaces in a string to end of string

  Returns:
  --------
  <cCrunched> string with spaces moved to end

  Syntax:
  -------
  CRUNCH(cOriginal,nAllor1)

  Description:
  ------------
  Moves spaces to end of string <cOriginal>. If
  <nAllor1> = 1, moves all but single spaces to right end of the
  string. If <nAllor1> = 0 moves all spaces to the right end.

  Examples:
  ---------

  cString := "SUPER    Library version 2.50"

  cString := CRUNCH(cString,1) // "SUPER Library version 2.50  "

  cString := CRUNCH(cString,0) // "SUPERLibraryversion2.50     "

  Notes:
  -------
  Handy for names (i.e. FIRST and LAST)

  Source:
  -------
  S_CRUNCH.PRG


Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson