An Interactive Hello World! Program

While you are digesting the OO information from the previous section, in the next few sections, I will present and analyze a C# source code example accompanied by an introduction to many of the fundamental aspects and features of the C# language. This will be a step toward your first object-oriented C# program presented in the last section of Chapter 5, which constitutes a simple, but working C# elevator simulation source program, directly related to our earlier, somewhat theoretical OO discussion.

Presenting Hello.cs

By tradition, the first program written in a new language prints the two words Hello World! onscreen. Because this is your second program (the first program Shakespeare.cs was in Chapter 2), we ...

Get C# Primer Plus now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.