C
C#4w ago
Rafell

How do i put "" Inside a String?

I wrote down "
Console.WriteLine("Welcome to "Program"")
Console.WriteLine("Welcome to "Program"")
" And it simply told me theres an error. How do i fix that?
2 Replies
Jimmacle
Jimmacle4w ago
you have to escape them, like "Welcome to \"Program\"" alternatively, you can use more quotes to start the string like """Welcome to "Program"""" in recent versions of C#
Rafell
Rafell4w ago
Oh interesting! Thank you Jimmacle. Or should i say. Danke Jimmacle.
Want results from more Discord servers?
Add your server