Advertisement
Guest User

Untitled

a guest
Oct 18th, 2019
98
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.77 KB | None | 0 0
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6.  
  7. namespace ConsoleApp3
  8. {
  9. class Var2
  10. {
  11. static public void Metod(char v1, char v2)
  12. {
  13. for (int i = v1; i<= v2;i++)
  14. {
  15. Console.Write(v1++ + " ");
  16. }
  17. }
  18. }
  19.  
  20. class Program
  21. {
  22. static void Main(string[] args)
  23. {
  24. char v1;
  25. char v2;
  26. Console.Write("First symbol: ");
  27. v1 = Convert.ToChar(Console.ReadLine());
  28. Console.Write("Second symbol: ");
  29. v2 = Convert.ToChar(Console.ReadLine());
  30. Var2.Metod(v1, v2);
  31. Console.ReadKey();
  32.  
  33. }
  34. }
  35. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement