Mathematica 9 is now available
Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
2005
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2005

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

Search the Archive

Re: Use strings in Mathematica, like in C?

  • To: mathgroup at smc.vnet.net
  • Subject: [mg61363] Re: [mg61354] Use strings in Mathematica, like in C?
  • From: Bob Hanlon <hanlonr at cox.net>
  • Date: Mon, 17 Oct 2005 02:29:28 -0400 (EDT)
  • Reply-to: hanlonr at cox.net
  • Sender: owner-wri-mathgroup at wolfram.com

StringReplacePart["string", "snew", {m, n}]

?StringReplacePart


Bob Hanlon

> 
> From: Renan <renan.birck at gmail.com>
To: mathgroup at smc.vnet.net
> Date: 2005/10/16 Sun AM 12:18:07 EDT
> Subject: [mg61363] [mg61354] Use strings in Mathematica, like in C?
> 
> Hello,
> 
> In the C programming language I can operate directly over the
> characters of a string, like:
> 
> int main() {
> 
>  char message[16] = "Hello!";
>  message[n]='a';
> 
> /* ... other code ... */
>  return(0);
> 
> }
> 
> This mean: Change the (n+1)th character (in C, array starts at 0) to the
> specified character.
> 
> Q: How can I obtain similar effect in Mathematica?
> 
> Thanks!
> --
> Thanks/obrigado, Renan "Wishmaster" Birck - Canoas, Rio Grande do Sul, 
Brasil
> MSN: wizard_of_yendor at hotmail.com
> Orkut: http://www.orkut.com/Profile.aspx?uid=2202360379963855296
> 
> 


  • Prev by Date: Re: Mathematica randomly stopping in M5.2 for Solaris
  • Next by Date: Re: Use strings in Mathematica, like in C?
  • Previous by thread: Re: Use strings in Mathematica, like in C?
  • Next by thread: Re: Use strings in Mathematica, like in C?