MathGroup Archive 2009

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: String substitution system


In[188]:= StringReplace["ABCXCDBXCBDXXBD", "X" ~~ Y_ :> Y ~~ "Z"]

(note the :> instead of the ->)


Cheers -- Sjoerd

On Mar 11, 12:08 pm, Hauke Reddmann <fc3a... at> wrote:
> THX for the answers. While I'm at it anyway,
> is it still that easy when I need substitution rules
> with placeholders? E.g. XY->YZ for fixed X,Z
> but any string Y?
> --
> Hauke Reddmann <:-EX8    fc3a... at
> Nur Schufte schuften - Genie genie=DFt.

  • Prev by Date: How to rotate a Histogram (Mathamatica 6)
  • Next by Date: Flipping axes on Graphics
  • Previous by thread: Re: String substitution system
  • Next by thread: Re: String substitution system