Simple, Quality, Awesome Software

Try It Out! (Third Edition)

Third Edition Second Edition First Edition

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 Minimum 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 Tic-Tac-Toe
21 Structs Quiz
22 Inheritance Quiz
23 Polymorphism Quiz
24 Interfaces Quiz
25 Generics Quiz
26 Building Your Own Generic List Class
26 Making Generics Quiz
27 Namespaces Quiz
28 Methods Revisited Quiz
30 Patterns Quiz
33 Delegates and Events Quiz
34 3D Vectors
34 Operator Overloading Quiz
35 Creating a Dictionary
36 Word Count
36 Sentence and Paragraph Count
36 Lines of Code
37 Lambda Expressions Quiz
38 Full Health
38 Percent Health
38 Back to Procedural Programming
38 Query Expressions Quiz
39 Frog Racing
40 Asynchronous Programming Quiz
41 Dynamic CSV Importer
48 Debugging Quiz
49 Demystifying Project Files
50 Message from Julius Caesar
50 Reverse It!
50 Pig Dice
50 Connect Four
50 Conway’s Game of Life