+ 1

How to extract a letter from a word using strings in c#

input=hello world output is h e l l o w o r l d

17th May 2017, 11:06 AM
Hadassah
Hadassah - avatar
5 Respostas
+ 3
@Luka I think Replace() function takes characters as parameters. So it should be : s = s.Replace(' ', ''); Edit : Sry, Didn't know. I always used characters. Thanks BTW.
17th May 2017, 11:25 AM
Cyrus Ornob Corraya
Cyrus Ornob Corraya - avatar
+ 1
Luka.. it is not an error bt exception that string cannot be of zero length... System.ArgumentException near replace
17th May 2017, 11:31 AM
Hadassah
Hadassah - avatar
+ 1
yeah I got it... thanks yaat
17th May 2017, 11:34 AM
Hadassah
Hadassah - avatar
0
not getting executed
17th May 2017, 11:21 AM
Hadassah
Hadassah - avatar
0
can u plz tell me how to remove those repeated letters after writing it letter by letter
17th May 2017, 11:39 AM
Hadassah
Hadassah - avatar