Mathematica > Core Language > String Manipulation > String Operations >

StringDrop

StringDrop["string", n]
gives "string" with its first n characters dropped.
StringDrop["string", -n]
gives "string" with its last n characters dropped.
StringDrop["string", {n}]
gives "string" with its n^(th) character dropped.
StringDrop["string", {m, n}]
gives "string" with characters m through n dropped.
StringDrop[{s1, s2, ...}, spec]
gives the list of results for each of the s_i.
  • StringDrop["string", {m, n, s}] drops characters m through n in steps of s.
  • StringDrop uses the standard Mathematica sequence specification.
New in 2 | Last modified in 5.1
© 2008 Wolfram Research, Inc.
Ask a question about this page  |  Suggest an improvement  |  Leave a message for the team