TryingToC#
December 13th, 2009, 12:13 AM
Hi everyone!
(I am using MS' Visual C# 2008 Express, in case that makes any difference...)
What I want to do is this: Take the content of a string (e.g. "Hello") and 'convert' it to an array that stores each character seperately (e.g. { "H", "e", "l", "l", "o" }). Can somebody tell me how to do that?
Additionally, is there a function that returns the index of an entity within an array? That is, if I was searching for an "e" in { "H", "e", "l", "l", "o" }, it'd return 1.
Sorry if these questions are dumb but I find it hard to come up with good key words for a google search. :/
Thanks in advance! (:
(I am using MS' Visual C# 2008 Express, in case that makes any difference...)
What I want to do is this: Take the content of a string (e.g. "Hello") and 'convert' it to an array that stores each character seperately (e.g. { "H", "e", "l", "l", "o" }). Can somebody tell me how to do that?
Additionally, is there a function that returns the index of an entity within an array? That is, if I was searching for an "e" in { "H", "e", "l", "l", "o" }, it'd return 1.
Sorry if these questions are dumb but I find it hard to come up with good key words for a google search. :/
Thanks in advance! (: