static void RunTask02() { // TODO: ввод и обработка пользовательского ввода. string[] chars = Console.ReadLine().Split(' '); if (chars.Length != 2) { Console.WriteLine("Incorrect input"); return; } char minChar = 'a'; char maxChar = 'a'; if (!GetValidData(ref minChar, chars[0]) || !GetValidData(ref maxChar, chars[1])) { return; } if (minChar > maxChar) { Console.WriteLine("Incorrect input"); return; } while (minChar <= maxChar) { LatinChar latinChar = new LatinChar(minChar); Console.WriteLine(latinChar._char); minChar = (char)(minChar + 1); } }
static void Main(string[] args) { double rmin = double.Parse(Console.ReadLine()); double rmax = double.Parse(Console.ReadLine()); double delta = double.Parse(Console.ReadLine()); int n = (int)(rmax - rmin) / (int)delta; LatinChar[] c = new LatinChar[n]; int k = 0; double m = 0; for (double i = rmin; i <= rmax; i += delta) { c[k] = new LatinChar((int)i); Console.WriteLine(c[k].CH); } Console.WriteLine(m); }
static void Main(string[] args) { do { Console.Clear(); char minChar = EnterChar("Введите нижнюю границу(символ) = "); char maxChar = EnterChar("Введите верхнюю границу(символ) = "); double delta = EnterDouble("Введите шаг = "); if (minChar < maxChar) { for (char i = minChar; i < maxChar; i += (char)delta) { LatinChar c = new LatinChar(i); Console.WriteLine($" char = {c.Char:F3}"); } } Console.WriteLine("To exit press ESC.../n To continue press any keyword"); } while (Console.ReadKey().Key != ConsoleKey.Escape); }