
2.
Use the address given in the
".NET
Documentation" section of this chapter. Open it and search in the
tree on the left side. A Google search
will work just as well and is often the fastest way to find documentation for a
given .NET class.
3.
Use the same approach as in the previous exercise.
4.
Follow the instruction from the
Compiling and Executing C# Programs
section.
5.
Use the code from the sample C#
program from this chapter and change the printed message.
6.
Find out how to use the System.Console.Write() method.
7.
Use the System.Console.WriteLine() method.
8.
Find out what features are
offered by the System.DateTime class.
9.
Find out what features are
offered by the System.Math class.
10. Try to learn on your own how to use loops in C#. You may read about for-loops in the chapter “Loops”.
11. Use the methods System.Console.ReadLine(), int.Parse() and
System.DateTime.AddYears().
12. Research them on the Internet (e.g. in Wikipedia)
and take a closer look at the differences between them. You will find that C# is a programming language while .NET Framework is development platform
and runtime for running .NET code. Be sure to read the section “The C#
Language and the .NET Platform” form this chapter.
13. Find out which are the most popular languages and examine some
sample programs written in them. Compare them to C#. You might take a look at C, C++,
Java, C#, VB.NET, PHP, JavaScript, Perl, Python and Ruby.
14. First download and install
JustDecompile or ILSpy (more information about them can be found
in the “Code Decompilation” section). After
you run one of them, open your program’s compiled file. It can be found in the bin\Debug
subdirectory of your C# project. For example, if your project is named TestCSharp and is located
in C:\Projects,
then the compiled assembly (executable file) of your program will be the
following file C:\Projects\TestCSharp\bin\Debug\TestCSharp.exe.
0 comments:
Post a Comment