static void Main() { StringBuilder inputCode = new StringBuilder(); while (true) { string line = Console.ReadLine(); inputCode.AppendLine(line); if (line.EndsWith("EXIT;")) break; } BasicLanguageExecutor parser = new BasicLanguageExecutor(); parser.ExecuteCode(inputCode.ToString()); Console.WriteLine(parser.GetOutput()); }
static void Main() { StringBuilder inputCode = new StringBuilder(); while (true) { string line = Console.ReadLine(); inputCode.AppendLine(line); if (line.EndsWith("EXIT;")) { break; } } BasicLanguageExecutor parser = new BasicLanguageExecutor(); parser.ExecuteCode(inputCode.ToString()); Console.WriteLine(parser.GetOutput()); }