Simple, Quality, Awesome Software

Try It Out! (Second Edition)

Third Edition Second Edition First Edition

Warning! This page is specific to an older version of the C# Player's Guide, and may not be the content you're looking for. For the latest version of this page, click here.

The C# Player’s Guide contains a wide variety of challenge problems designed to help you get some hands on practice with the topics it discusses. On this page, you’ll find links to answers for each of these Try It Out! problems so that you can check your work, or get some ideas on how to progress, if you get stuck trying them.

As you look at these, remember that there is always more than one way to write code that accomplishes a single task. Just because your version is different than what you see doesn’t mean it’s wrong.

If you discover any problems or bugs in the sample code provided here, please report it so we can fix it.

Chapter Title
2 Installing Visual Studio
3 Hello World!
3 See Your Program Twice
3 Evil Computers
4 Comment ALL the Things!
5 Playing with Variables
5 Variables Quiz
6 Variables Everywhere
6 Types Quiz
7 Area of a Triangle
7 Remainders
8 Cylinders: A Complete Program
9 Casting and Order of Operations
10 Even and Odd
10 Positive or Negative
11 Making a Calculator
12 Print-a-Pyramid
12 FizzBuzz
13 Copying an Array
13 Totaling and Averaging Revisited
14 Months of the Year
15 Reversing and Array
15 The Fibonacci Sequence
16 Value and Reference Types Quiz
17 Die Rolling
18 Designing and Building Classes
18 Classes Quiz
19 Playing with Properties
20 Structs Quiz
21 Inheritance Quiz
22 Polymorphism Quiz
23 Interfaces Quiz
25 Building Your Own Generic List Class
25 Generics Quiz
26 Namespaces Quiz
27 Methods Revisited Quiz
31 Delegates and Events Quiz
32 Frog Racing
33 3D Vectors
33 Operator Overloading Quiz
34 Creating a Dictionary
35 Word Count
35 Sentence and Paragraph Count
35 Lines of Code
36 Lambda Expressions Quiz
37 BMI
37 Back to Procedural Programming
39 .NET Framework Quiz
43 Debugging Quiz
44 Demystifying Project Files
45 Message from Julius Caesar
45 Reverse It!
45 Pig Dice
45 Connect Four
45 Conway’s Game of Life