Skip to main content

3 docs tagged with "console"

View all tags

Basic Console Input and Output in C#

Welcome to a new series on building your first .NET console applications! We'll start with the most fundamental building blocks of any interactive program: getting input from the user and displaying output. In C#, this is primarily handled by the Console.ReadLine() and Console.WriteLine() methods.

Your First .NET Console App: "Hello, World!" (Part 1) - Using the Command Line

After setting up your development environment in Setting Up Your .NET Development Environment (Part 2), it's finally time to write and run your very first C# .NET application! The traditional first program in any new language is "Hello, World!". In this article (Part 1), we'll focus on creating, building, and running this simple console application entirely using the .NET Command Line Interface (CLI). This approach helps solidify your understanding of the underlying tools before relying heavily on an IDE.

Your First .NET Console App: "Hello, World!" (Part 2) - Understanding the Code

In Your First .NET Console App: \"Hello, World!\" (Part 1) - Using the Command Line, we successfully created and ran our first "Hello, World!" application using the .NET CLI. Now, in Part 2, we'll shift our focus to the C# code itself. We'll dissect the structure of the Program.cs file, understand the role of the Main method (even when it's implicit), explore the Console.WriteLine() method in more detail, and touch upon basic C# syntax elements like comments and string interpolation.