If you're new to C#, this popular book is the ideal way to get started. Completely revised for the latest version of the language, Learning C# 2008 starts with the most basic features of the language, and builds to advanced features including generics, interfaces, and delegates. You'll also learn how to build Windows applications and handle data with C#.
No previous programming experience is required -- in fact, if you've never written a line of code in your life, this book will show you how it's done. Bestselling authors Jesse Liberty and Brian MacDonald start with the fundamentals and work up through intermediate to advanced features. Each chapter offers a self-contained lesson that helps you master key concepts, with plenty of annotated examples, illustrations, and a concise summary.
* Learn how to program while you learn C#
* Learn principles of object-oriented programming through C#
* Discover how to use the latest features in C# 3.0 and the .NET 3.5 Framework -- including LINQ and the Windows Presentation Foundation (WPF)
* Create Windows applications and data-driven applications
* Sharpen your skills with "Brain Builder" quizzes and exercises in each chapter
If you're ready to dive into C# and .NET programming, this book is a great way to quickly get up to speed.
Preface
About This Book Who This Book Is For How This Book Is Organized Conventions Used in This Book Support: A Note from Jesse Liberty Using Code Examples We'd Like to Hear from You Safari? Books Online Acknowledgments
Chapter 1: C# and NET Programming
1.
1 Installing C# Express
1.
2 C#
3.
0 and NET
3.
5
1.
3 The NET Platform
1.
4 The NET Framework
1.
5 The C# Language
1.
6 Your First Program: Hello World
1.
7 The Compiler
1.
8 Examining Your First Program
1.
9 The Integrated Development Environment
1.
10 Summary
1.
11 Test Your Knowledge: Quiz
1.
12 Test Your Knowledge: Exercise
Chapter 2: Visual Studio 2008 and C# Express 2008
2.
1 Before You Read Further
2.
2 The Start Page
2.
3 Projects and Solutions
2.
4 Inside the Integrated Development Environment
2.
5 Building and Running Applications
2.
6 Menus
2.
7 Summary
2.
8 Test Your Knowledge: Quiz
2.
9 Test Your Knowledge: Exercises
Chapter 3: C# Language Fundamentals
3.
1 Statements
3.
2 Types
3.
3 WriteLine( ) and Output
3.
4 Variables and Assignment
3.
5 Casting
3.
6 Constants
3.
7 Strings
3.
8 Whitespace
3.
9 Summary
3.
10 Test Your Knowledge: Quiz
3.
11 Test Your Knowledge: Exercises
Chapter 4: Operators
4.
1 Expressions
4.
2 The Assignment Operator (=)
4.
3 Mathematical Operators
4.
4 Increment and Decrement Operators
4.
5 Relational Operators
4.
6 Logical Operators and Conditionals
4.
7 The Conditional Operator
4.
8 Operator Precedence
4.
9 Summary
4.
10 Test Your Knowledge: Quiz
4.
11 Test Your Knowledge: Exercises
Chapter 5: Branching
5.
1 Unconditional Branching Statements
5.
2 Conditional Branching Statements
5.
3 ReadLine( ) and Input
5.
4 Iteration (Looping) Statements
5.
5 Summary
5.
6 Test Your Knowledge: Quiz
5.
7 Test Your Knowledge: Exercises
Chapter 6: Object-Oriented Programming
6.
1 Creating Models
6.
2 Classes and Objects
6.
3 Defining a Class
6.
4 Class Relationships
6.
5 The Three Pillars of Object-Oriented Programming
6.
6 Object-Oriented Analysis and Design
6.
7 Summary
6.
8 Test Your Knowledge: Quiz
6.
9 Test Your Knowledge: Exercises
Chapter 7: Classes and Objects
7.
1 Defining Classes
7.
2 Method Arguments
7.
3 Return Types
7.
4 Constructors
7.
5 Initializers
7.
6 Object Initializers
7.
7 Anonymous Types 7