Sep 4, 2024
static void Main(string[] args)
.Console.WriteLine()
to display text.//
for single-line, /*...*/
for multi-line.\n
for new line, \t
for tab.Console.Beep();
for sound.int x
.x = 10
.int
, double
, bool
, char
, string
.const
keyword.Convert.ToInt32()
, Convert.ToDouble()
, etc.int to double
, string to int
.Console.ReadLine()
to get user input.Convert
methods as needed.+
, -
, *
, /
, %
.++
, --
.+=
, -=
, *=
, /=
.Math.Pow()
, Math.Sqrt()
, Math.Abs()
, Math.Round()
.Random
class: Random rand = new Random();
.Next()
, NextDouble()
.ToUpper()
, ToLower()
, Replace()
, Insert()
, Substring()
..Length
to get string length.if-else
.&&
(AND), ||
(OR).static void MethodName() {}
.try
, catch
, finally
blocks for error handling.