How to add double quotes to a string in C#

2 Answers

0 votes
using System;

namespace ConsoleApplication_C_Sharp
{
    static class Program
    {
        static void Main()
        {
            string s = @"""C# Java Python""";

            Console.WriteLine(s);
        }
    }
}


/*
run:
  
"C# Java Python"
   
*/

 



answered Oct 14, 2018 by avibootz
0 votes
using System;

namespace ConsoleApplication_C_Sharp
{
    static class Program
    {
        static void Main()
        {
            string s = "\"C# Java Python\"";

            Console.WriteLine(s);
        }
    }
}


/*
run:
  
"C# Java Python"
   
*/

 



answered Oct 14, 2018 by avibootz

Related questions

1 answer 79 views
2 answers 255 views
2 answers 197 views
2 answers 128 views
1 answer 123 views
1 answer 117 views
...