Book Image

Learn C# in 7 days

By : Gaurav Aroraa
1 (1)
Book Image

Learn C# in 7 days

1 (1)
By: Gaurav Aroraa

Overview of this book

This book takes a unique approach to teach C# to absolute beginners. You’ll learn the basics of the language in seven days. It takes a practical approach to explain the important concepts that build the foundation of the C# programming language. The book begins by teaching you the basic fundamentals using real-world practical examples and gets you acquainted with C# programming. We cover some important features and nuances of the language in a hands-on way, helping you grasp the concepts in a fluid manner. Later, you’ll explore the concepts of Object-Oriented Programming (OOP) through a real-world example. Then we dive into advanced-level concepts such as generics and collections, and you’ll get acquainted with objects and LINQ. Towards the end, you’ll build an application that covers all the concepts explained in the book. By the end of this book, you will have next-level skills and a good knowledge of the fundamentals of C#.
Table of Contents (15 chapters)
Title Page
Credits
About the Author
About the Reviewer
www.PacktPub.com
Customer Feedback
Preface

Revisiting Day 03


Today, we have discussed all the new features introduced in C# 7.0 with code examples. We also understood the important points and usage of these features.

We discussed how ValueTuples help us gather the data information and the cases where we are expecting multiple outputs from a method. One of the good points of ValueTuple is that this is a mutable and ValueType. There are a few public and static methods provided by System.ValueTuple and we can achieve many complex scenarios with the use of these.

Then we came to know the advantage and power of pattern matching; this helps the coder perform various complex conditional scenarios which were not possible in prior versions of the C# language. The type pattern and the when clause in case statements makes this feature superb.

Local functions are one of the most important features introduced in C# 7.0. They help a lot in a scenario, where we need to make our code symmetric, so you can read code perfectly and when we do not require...