Advertisement
filipovv

magicLetters

May 31st, 2017
116
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.79 KB | None | 0 0
  1. using System;
  2.  
  3. namespace MagicLetter
  4. {
  5.     class MainClass
  6.     {
  7.         public static void Main(string[] args)
  8.         {
  9.             char one = char.Parse(Console.ReadLine());
  10.             char two = char.Parse(Console.ReadLine());
  11.             char three = char.Parse(Console.ReadLine());
  12.  
  13.             for (int i = one; i <= two; i++)
  14.             {
  15.                 for (int j = one; j <=two; j++)
  16.                 {
  17.                     for (int k = one; k <= two; k++)
  18.                     {
  19.                         if ((char)i!=three&&(char)j!=three&&(char)k!=three)
  20.                         {
  21.                             Console.Write($"{(char)i}{(char)j}{(char)k}");
  22.                             Console.Write(' ');
  23.                         }
  24.                     }
  25.                 }
  26.             }
  27.  
  28.  
  29.  
  30.         }
  31.     }
  32. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement