terminate console application c# code example
Example 1: how to exit application c# console
System.Environment.Exit(0);
// or
Environment.Exit(0);
Example 2: c# how to terminate console application
System.Envrionment.Exit(0);
//or
Envrionment.Exit(0);