Concatenation of two strings using $ C# with Example



Concatenation of two strings using $ C# with Example

$ provides an easy and a concise method to concatenate multiple strings. 
var str1 = "text1"; 
var str2 = " "; 
var str3 = "text3"; 
string result2 = $"{str1}{str2}{str3}"; //"text1 text3" 
 

0 Comment's

Comment Form

Submit Comment