Language: C++

using System;
using System.Collections.Generic;

namespace ConsoleApp_CS
{
    class Program
    {
        static void Main(string[] args)
        {
            var n = CIn.ReadIntArray(2);
            foreach(var item in n)
            {
                if (item > 9)
                {
                    Console.WriteLine(-1);
                    return;
                }
            }
            Console.WriteLine(n[0] * n[1]);
            
        }
    }

    class CIn
    {
        private static readonly Queue<string> fieldBuffer = new Queue<string>();

        public static string Read()
        {
            if (fieldBuffer.Count == 0)
            {
                foreach (var field in Console.ReadLine().Split())
                {
                    fieldBuffer.Enqueue(field);
                }
            }
            return fieldBuffer.Dequeue();
        }

        public static int ReadInt() => int.Parse(Read());
        public static long ReadLong() => long.Parse(Read());
        public static double ReadDouble() => double.Parse(Read());

        public static string[] ReadStringArray(long n)
        {
            var array = new string[n];
            for (var i = 0; i < n; i++)
            {
                array[i] = Read();
            }
            return array;
        }

        public static int[] ReadIntArray(long n)
        {
            var array = new int[n];
            for (var i = 0; i < n; i++)
            {
                array[i] = ReadInt();
            }
            return array;
        }

        public static long[] ReadLongArray(long n)
        {
            var array = new long[n];
            for (var i = 0; i < n; i++)
            {
                array[i] = ReadLong();
            }
            return array;
        }

        public static double[] ReadDoubleArray(long n)
        {
            var array = new double[n];
            for (var i = 0; i < n; i++)
            {
                array[i] = ReadDouble();
            }
            return array;
        }
    }
}


Compiler output:
a.cc:1:7: error: expected nested-name-specifier before 'System'
    1 | using System;
      |       ^~~~~~
a.cc:2:7: error: expected nested-name-specifier before 'System'
    2 | using System.Collections.Generic;
      |       ^~~~~~
a.cc:8:26: error: 'string' has not been declared
    8 |         static void Main(string[] args)
      |                          ^~~~~~
a.cc:8:35: error: expected ',' or '...' before 'args'
    8 |         static void Main(string[] args)
      |                                   ^~~~
a.cc:22:6: error: expected ';' after class definition
   22 |     }
      |      ^
      |      ;
a.cc: In static member function 'static void ConsoleApp_CS::Program::Main(int*)':
a.cc:10:13: error: 'var' was not declared in this scope
   10 |             var n = CIn.ReadIntArray(2);
      |             ^~~
a.cc:11:25: error: expected ')' before 'item'
   11 |             foreach(var item in n)
      |                         ^~~~
a.cc:11:20: note: to match this '('
   11 |             foreach(var item in n)
      |                    ^
a.cc:11:13: error: 'foreach' was not declared in this scope
   11 |             foreach(var item in n)
      |             ^~~~~~~
a.cc:19:13: error: 'Console' was not declared in this scope
   19 |             Console.WriteLine(n[0] * n[1]);
      |             ^~~~~~~
a.cc:19:31: error: 'n' was not declared in this scope
   19 |             Console.WriteLine(n[0] * n[1]);
      |                               ^
a.cc: At global scope:
a.cc:26:16: error: expected ':' before 'static'
   26 |         private static readonly Queue<string> fieldBuffer = new Queue<string>();
      |                ^~~~~~~
      |                :
a.cc:26:24: error: 'readonly' does not name a type
   26 |         private static readonly Queue<string> fieldBuffer = new Queue<string>();
      |                        ^~~~~~~~
a.cc:28:15: error: expected ':' before 'static'
   28 |         public static string Read()
      |               ^~~~~~~
      |               :
a.cc:28:23: error: 'string' does not name a type
   28 |         public static string Read()
      |                       ^~~~~~
a.cc:40:15: error: expected ':' before 'static'
   40 |         public static int ReadInt() => int.Parse(Read());
      |               ^~~~~~~
      |               :
a.cc:40:40: error: invalid pure specifier (only '= 0' is allowed) before 'int'
   40 |         public static int ReadInt() => int.Parse(Read());
      |                                        ^~~
a.cc:40:27: error: initializer specified for static member function 'static int ConsoleApp_CS::CIn::ReadInt()'
   40 |         public static int ReadInt() => int.Parse(Read());
      |                           ^~~~~~~
a.cc:41:15: error: expected ':' before 'static'
   41 |         public static long ReadLong() => long.Parse(Read());
      |               ^~~~~~~
      |               :
a.cc:41:42: error: invalid pure specifier (only '= 0' is allowed) before 'long'
   41 |         public static long ReadLong() => long.Parse(Read());
      |                                          ^~~~
a.cc:41:28: error: initializer specified for static member function 'static long int ConsoleApp_CS::CIn::ReadLong()'
   41 |         public static long ReadLong() => long.Parse(Read());
      |                            ^~~~~~~~
a.cc:42:15: error: expected ':' before 'static'
   42 |         public static double ReadDouble() => double.Parse(Read());
      |               ^~~~~~~
      |               :
a.cc:42:46: error: invalid pure specifier (only '= 0' is allowed) before 'double'
   42 |         public static double ReadDouble() => double.Parse(Read());
      |                                              ^~~~~~
a.cc:42:30: error: initializer specified for static member function 'static double ConsoleApp_CS::CIn::ReadDouble()'
   42 |         public static double ReadDouble() => double.Parse(Read());
      |                              ^~~~~~~~~~
a.cc:44:15: error: expected ':' before 'static'
   44 |         public static string[] ReadStringArray(long n)
      |               ^~~~~~~
      |               :
a.cc:44:23: error: 'string' does not name a type
   44 |         public static string[] ReadStringArray(long n)
      |                       ^~~~~~
a.cc:54:15: error: expected ':' before 'static'
   54 |         public static int[] ReadIntArray(long n)
      |               ^~~~~~~
      |               :
a.cc:54:26: error: expected unqualified-id before '[' token
   54 |         public static int[] ReadIntArray(long n)
      |                          ^
a.cc:64:15: error: expected ':' before 'static'
   64 |         public static long[] ReadLongArray(long n)
      |               ^~~~~~~
      |               :
a.cc:64:27: error: expected unqualified-id before '[' token
   64 |         public static long[] ReadLongArray(long n)
      |                           ^
a.cc:74:15: error: expected ':' before 'static'
   74 |         public static double[] ReadDoubleArray(long n)
      |               ^~~~~~~
      |               :
a.cc:74:29: error: expected unqualified-id before '[' token
   74 |         public static double[] ReadDoubleArray(long n)
      |                             ^
a.cc:83:6: error: expected ';' after class definition
   83 |     }
      |      ^
      |      ;