How to get the second char from a string in C#

1 Answer

0 votes
using System;

class Program
{
    static void Main() {
        String s = "c# sharp";  
  
        Console.WriteLine(s[1]);  
    }
}


/*
run:

#

*/

 



answered Oct 31, 2019 by avibootz

Related questions

1 answer 172 views
1 answer 169 views
1 answer 135 views
135 views asked Oct 31, 2019 by avibootz
2 answers 204 views
204 views asked Oct 31, 2019 by avibootz
1 answer 225 views
1 answer 149 views
...