官术网_书友最值得收藏!

Discussing code

We have gone through the console application and discussed what a typical console application contains and how we can set various things using Visual Studio. Now let's discuss our code, which was written in the previous section, Understanding a typical C# program.

Console is a static class of a System namespace and it can't be inherited.

In the said code, we instructed the program to write something to the console as an output with the help of the WriteLine() method.

The official definition of Console class is as follows (https://docs.microsoft.com/en-us/dotnet/api/system.console?view=netcore-2.0):

Represents the standard input, output, and error streams for console applications. This class cannot be inherited.

Console is nothing but an operating system's terminal-windows (also known as Console User Interface (CUI))to interact with users. Windows operating system has console, that is, Command Prompt that accepts MS-DOS commands. In this way, the Console class provides basic support to achieve this.

Here are a few important operations we can do with the console.

主站蜘蛛池模板: 自治县| 高碑店市| 马公市| 九江市| 武功县| 普陀区| 绥阳县| 临西县| 恩平市| 濮阳县| 宜宾县| 连南| 中超| 岢岚县| 镇江市| 宜昌市| 宣汉县| 赫章县| 东兴市| 左权县| 江源县| 台湾省| 千阳县| 浦县| 赣榆县| 阿勒泰市| 沙湾县| 连平县| 蕲春县| 育儿| 咸宁市| 泽普县| 嘉禾县| 南昌县| 常山县| 当阳市| 剑川县| 万年县| 阿图什市| 罗江县| 科技|