Book description
C# Primer Plus teaches the C# programming language and relevant parts of the .NET platform from the ground up, walking you through the basics of object-oriented programming, important programming techniques and problem solving while providing a thorough coverage of C#'s essential elements - such as classes, objects, data types, loops, branching statements, arrays, and namespaces.
In early chapters guided tours take you sightseeing to the main attractions of C# and provide a fast learning-path that enables you to quickly write simple C# programs. Your initial programming skills are then gradually expanded, through the many examples, case studies, illustrations, review questions and programming exercises, to include powerful concepts - like inheritance, polymorphism, interfaces and exception handling, along with C#'s most innovative features - such as properties, indexers, delegates and events.
With C# Primer Plus's dual emphasis on C# as well as fundamental programming techniques, this friendly tutorial will soon make you a proficient C# programmer building Windows applications on the .NET platform.
Table of contents
- Copyright
- ABOUT THE AUTHOR
- ACKNOWLEDGMENTS
- TELL US WHAT YOU THINK!
- INTRODUCTION
- COMPUTERS AND COMPUTER PROGRAMMING: BASIC CONCEPTS
-
YOUR FIRST C# PROGRAM
- Software Development
- The Software Development Process
- Algorithms and Pseudocode
- The Three Different Types of Errors
- Object-Oriented Programming: A First Encounter
- Software Reuse
- The Assembly, the Basic Unit of Code Reuse in .NET
- The .NET Framework Class Library
- C#: History and Design Goals
- C#'s Background
- C#'s Design Goals
- What Kind of Programs Can I Write with C#?
- The Mechanics of Creating a C# Program
- Before Getting Started
- Choosing a Text Editor
- The Seven Steps to Writing a Simple C# Program
- A Brief Source Code Analysis
- Note on Syntax Errors and Compilers
- Summary
- Review Questions
- Programming Exercises
- A GUIDED TOUR THROUGH C#: PART I
- A GUIDED TOUR THROUGH C#: PART II
- YOUR FIRST OBJECT-ORIENTED C# PROGRAM
- TYPES PART I: THE SIMPLE TYPES
-
TYPES PART II: OPERATORS, ENUMERATORS, AND STRINGS
- Introduction
- Arithmetic Operators and Numerical Expressions
- Associativity
- Parentheses and Precedence
- The Modulus Operator (%)
- Unary Operators
- Determining the Type of an Expression
- Combining Different Types in One Expression
- Accessing the Metadata of a Component: A Brief Introduction
- Enumerated Constants
- Enumerator Operators
- Conversions
- The Methods of System.Enum
- Characters and Text
- The char Type
- The string type
- Summary
- Review Questions
- Programming Exercises
-
FLOW OF CONTROL PART I: BRANCHING STATEMENTS AND RELATED CONCEPTS
- Introduction to Flow of Control
- Branching with the if Statement
- Comparison Operators and Boolean Expressions
- Nested if Statements
- Multibranch if-else Statements
- Logical Operators
- The Scope of Variables
- The goto Statement
- The switch Statement
- The Conditional Operator
- Summary
- Review Questions
- Programming Exercises
-
FLOW OF CONTROL PART II: ITERATION STATEMENTS
- Traversing, Analyzing, and Generating Sequences of Data
- The while Loop Statement
- The do-while Loop Statement
- The for Loop Statement
- The Jump Statements break and continue
- Structured Programming and Structured Constructs
- Combination Assignment Operators
- Nested Iteration Statements
- Programming Exercises
- Summary
- Review Questions
- Programming Exercises
-
ARRAYS PART I: ARRAY ESSENTIALS
- Declaring and Defining an Array
- Accessing Individual Array Elements
- Array Indexes Out of Range
- Adjusting for the Zero-Based Array Index
- Initializing Arrays
- Traversing an Entire Array with the foreach Statement
- System.Array Is a Reference Type
- Arrays and Equality
- Arrays and Methods
- A Method to Perform Array Value Equality Comparisons
- Command Line Arguments
- Using Arrays As Return Values from Methods
- Array Elements Referencing Objects
- Arrays As Instance Variables in Classes
- Summary
- Review Questions
- Programming Exercises
- ARRAYS PART II: MULTIDIMENSIONAL ARRAYS—SEARCHING AND SORTING ARRAYS
- CLASS ANATOMY PART I: static CLASS MEMBERS AND METHOD ADVENTURES
- CLASS ANATOMY PART II: OBJECT CREATION AND GARBAGE COLLECTION
- CLASS ANATOMY PART III: WRITING INTUITIVE CODE
- NAMESPACES, COMPILATION UNITS, AND ASSEMBLIES
-
INHERITANCE PART I: BASIC CONCEPTS
- The Need for Inheritance
- Inheritance Fundamentals
- Access Modifiers and Inheritance
- Derived Class Constructors
- Indexers Are Also Inherited and Can Be Overridden
- Calling an Overridden Function in the Base Class
- Reusing the .NET Framework Class Library with Inheritance
- Multiple Levels of Derived Classes
- Method Overriding and Overloading Are Different Mechanisms
- Summary
- Review Questions
- Programming Exercises
- INHERITANCE PART II: abstract FUNCTIONS, POLYMORPHISM, and INTERFACES
- STRUCTS
-
EXCEPTION HANDLING
- Exception Handling: A Brief Overview
- Life without try-catch-finally
- The try and catch blocks
- Catching the Exception Object Farther up the Function Call Chain
- Multiple catch Blocks
- The finally Block
- Nested try Blocks
- throw: Explicitly Throwing Exceptions
- Writing Custom Exceptions
- Summary
- Review Questions
- Programming Exercises
- DELEGATES AND EVENTS
- PREPROCESSING, XML DOCUMENTATION, AND ATTRIBUTES
- FILE I/O BASICS
- RECURSION FUNDAMENTALS
- ANSWERS TO QUIZZES AND EXERCISES
- Index
Product information
- Title: C# Primer Plus
- Author(s):
- Release date: December 2001
- Publisher(s): Sams
- ISBN: 0672321521
You might also like
book
C# Unleashed
Part I provides the most basic elements of C# language syntax. Part II covers object and …
book
C# Essentials
Concise but thorough, C# Essentials introduces the brand-new Microsoft C# programming language and the Microsoft .NET …
book
Learning C# 3.0
If you're new to C#, this popular book is the ideal way to get started. Completely …
book
C# 4.0 The Complete Reference
The Definitive Guide to C# “From using LINQ to covariance and from string formatting to optional …