title: C# classes - basic example
body: <p>This is basically my first attempt to understand the classes in C#. I've went through several tutorials on the internet, but the thing I'm missing the most and what I haven't found anywhere yet, is a simple good example.</p>
  
  <p>I have some idea how my basic program should look like and I would appreciate your help:</p>
  
  <pre><code>using System;
  
  namespace Introduction_to_classes
  {
      class Person
      {
          int Age;
          string Name;
  
          int DateOfBirth()
          {
              return 2013 - Age;
          }
      }
  
      class Program
      {
          public static void Main()
          {
              Person Mother = new Person(35, Alice);
              Person Son = new Person(12, Johny);
  
              Mother.Name = "Lucy";  // Just changing the value afterwards
  
              if(Mother.Age &gt; Son.Age)
              {
                  int year = Mother.DateOfBirth();
                  Console.WriteLine("Mom was born in {0}.", year);
              }
  
              Console.ReadLine();
          }
      }
  }
  </code></pre>
  
  <p>It's just an idea, it definitely doesn't work. But more than anything else it would help me if you can correct it to the working example...</p>