C# Parameter Exercise

practicenote-01
In this chapter, some C# programming exercises are given that will clear your concept of value type, reference type out parameter and command line argument. Try to solve these programming exercises yourself.

Exercise 1: Explain difference between value type and reference type by writing a suitable C# example.
Exercise 2: Write a program in which accept four numbers from the user and returns add, subtraction and multiplication of the value using out parameter.
Exercise 3: Write a C# program to demonstrate command line argument. Accept 2 numbers from the user and calculate area and perimeter of rectangle.

Summary

In this chapter you did some programming exercises of parameters. In next session you will learn about Array in C#.



Leave a Reply

Your email address will not be published. Required fields are marked *