C# How To Add Two Numbers
Discover how to use C# to add two numbers:
Example
int x = 5;
int y = 6;
int sum = x + y;
Console.WriteLine(sum); // Print the sum of x + y
C# Examples
C# Syntax
create a sample “hello world” program
using System;
namespace HelloWorld
{
class Program
{
static void Main(string[] args)
{
Console.WriteLine(“Hello World!”);
}
}
}