CSharp examples for Language Basics:string
Output value via string interpolation
using static System.Console; class Program//from www .j a v a 2 s . c om { static double Add(double a, double b) { return a + b; // deliberate bug! } static void Main(string[] args) { double a = 4.5; // or use var double b = 2.5; double answer = Add(a, b); WriteLine($"{a} + {b} = {answer}"); } }