MathGroup Archive 2009

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

Search the Archive

Re: Number of Words in a String

  • To: mathgroup at smc.vnet.net
  • Subject: [mg102534] Re: Number of Words in a String
  • From: meitnik <meitnik at gmail.com>
  • Date: Wed, 12 Aug 2009 04:36:58 -0400 (EDT)
  • References: <h5r8b5$l4q$1@smc.vnet.net>

hi,

Try this:

CountWords[str_String]:=Length[StringSplit[str]]

Its not perfect, still working on it. I suspect only via a RegEx use
will we get what we want.

andrew


  • Prev by Date: Re: Dynamically create array and display data graphically
  • Next by Date: Re: Number of Words in a String
  • Previous by thread: Re: Number of Words in a String
  • Next by thread: Re: Number of Words in a String