- using System.IO;
- using System;
- class Person {
- public string Name {
- get;
- private set;
- }
- public Person(string name) {
- Name = name;
- }
- }
- class UsingPerson {
- public static void Main() {
- Person Programmer = new Person("Progr. Rajan singh");
- Console.WriteLine("Name: {0}", Programmer.Name);
- }
- }
Output
Name: Progr. Rajan singh