Advertisement
Venciity

[Jumpstart C#] Console Demos - Printing letter

Jan 22nd, 2014
107
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.65 KB | None | 0 0
  1. using System;
  2.  
  3. class PrintingLetter
  4. {
  5.     static void Main()
  6.     {
  7.         Console.Write("Enter person name: ");
  8.         string person = Console.ReadLine();
  9.  
  10.         Console.Write("Enter company name: ");
  11.         string company = Console.ReadLine();
  12.  
  13.         Console.WriteLine("  Dear {0},", person);
  14.         Console.WriteLine(
  15.             "We are pleased to tell you " +
  16.             "that {0} has chosen you to take part " +
  17.             "in the \"Introduction To Programming\" " +
  18.             "course. {0} wishes you good luck!",
  19.             company);
  20.  
  21.         Console.WriteLine("  Yours,");
  22.         Console.WriteLine("  {0}", company);
  23.     }
  24. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement