Language: C++

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using sc = Scanner;

class Program
{
    static void Main(string[] args)
    {
        var q = new AnswerCollecter<string>();

        while (true)
        {
            int n, m;
            int[][] jem, move;
            int x, y;
            int count = 0;
            n = sc.NextInt();
            jem = new int[n][];
            if (n == 0)
            {
                q.Answer();
                break;
            }
            for (int i = 0; i < n; i++)
            {
                jem[i] = sc.NextIntArray();
            }
            m = sc.NextInt();
            move = new int[m][];
            for (int i = 0; i < m; i++)
            {
                move[i] = new int[2];
                switch (sc.NextString())
                {
                    case "N":
                        move[i][1] = sc.NextInt();
                        continue;
                    case "E":
                        move[i][0] = sc.NextInt();
                        continue;
                    case "S":
                        move[i][1] = -sc.NextInt();
                        continue;
                    case "W":
                        move[i][0] = -sc.NextInt();
                        continue;
                    default:
                        continue;
                }
            }
            x = y = 10;
            for (int i = 0; i < n; i++)
            {
                x += move[i][0];
                y += move[i][1];
                for (int j = 0; j < n; j++)
                    if (x == jem[j][0] && y == jem[j][1])
                    {
                        count++;
                        jem[j][0] = -1; //重複して宝石を拾わないようにする
                        jem[j][1] = -1;
                    }
            }
            q.Enqueue(count == n ? "YES" : "NO");
        }
    }
}

public class AnswerCollecter<T>
{
    private Queue<T> q;

    public AnswerCollecter()
    {
        q = new Queue<T>();
    }

    public void Enqueue( T item)
    {
        q.Enqueue(item);
    }

    public void Answer()
    {
        while (q.Count != 0)
            Console.WriteLine(q.Dequeue());
    }
}
   
public static class Scanner
{
    public static string NextString()
    {
        string tmp = "";
        while (true)
        {
            string readData = char.ConvertFromUtf32(Console.Read());
            if (readData == " " || readData == "\n")
                break;
            tmp += readData;
        }
        return tmp;
    }

    public static string[] NextStrArray()
    {
        return Console.ReadLine().Split(' ');
    }

    public static long[] NextLongArray()
    {
        string[] s = NextStrArray();
        long[] a = new long[s.Length];
        for (int i = 0; i < a.Length; i++)
        {
            a[i] = long.Parse(s[i]);
        }
        return a;
    }
    public static int[] NextIntArray()
    {

        string[] s = NextStrArray();
        int[] a = new int[s.Length];
        for (int i = 0; i < a.Length; i++)
        {
            a[i] = int.Parse(s[i]);
        }
        return a;
    }
    public static int NextInt()
    {
        string tmp = "";
        while (true)
        {
            string readData = char.ConvertFromUtf32(Console.Read());
            if (readData == " " || readData == "\n")
                break;
        
            tmp += readData;
        }
        return int.Parse(tmp);
    }
    public static double NextDouble()
    {
        string tmp = "";
        while (true)
        {
            string readData = char.ConvertFromUtf32(Console.Read());
            if (readData == " " || readData == "\n")
                break;
            tmp += readData;
        }
        return double.Parse(tmp);
    }
    public static long NextLong()
    {
        string tmp = "";
        while (true)
        {
            string readData = char.ConvertFromUtf32(Console.Read());
            if (readData == " " || readData == "\n")
                break;
            tmp += readData;
        }
        return long.Parse(tmp);
    }
    public static double[] NextDoubleArray()
    {

        string[] s = NextStrArray();
        double[] a = new double[s.Length];
        for (int i = 0; i < a.Length; i++)
        {
            a[i] = double.Parse(s[i]);
        }
        return a;
    }
}

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:3:7: error: expected nested-name-specifier before 'System'
    3 | using System.Linq;
      |       ^~~~~~
a.cc:4:7: error: expected nested-name-specifier before 'System'
    4 | using System.Text;
      |       ^~~~~~
a.cc:5:12: error: 'Scanner' does not name a type
    5 | using sc = Scanner;
      |            ^~~~~~~
a.cc:9:22: error: 'string' has not been declared
    9 |     static void Main(string[] args)
      |                      ^~~~~~
a.cc:9:31: error: expected ',' or '...' before 'args'
    9 |     static void Main(string[] args)
      |                               ^~~~
a.cc:69:2: error: expected ';' after class definition
   69 | }
      |  ^
      |  ;
a.cc: In static member function 'static void Program::Main(int*)':
a.cc:11:9: error: 'var' was not declared in this scope
   11 |         var q = new AnswerCollecter<string>();
      |         ^~~
a.cc:16:16: error: structured binding declaration cannot have type 'int'
   16 |             int[][] jem, move;
      |                ^~
a.cc:16:16: note: type must be cv-qualified 'auto' or reference to cv-qualified 'auto'
a.cc:16:16: error: empty structured binding declaration
a.cc:16:18: error: expected initializer before '[' token
   16 |             int[][] jem, move;
      |                  ^
a.cc:19:17: error: 'sc' was not declared in this scope
   19 |             n = sc.NextInt();
      |                 ^~
a.cc:20:13: error: 'jem' was not declared in this scope
   20 |             jem = new int[n][];
      |             ^~~
a.cc:20:30: error: expected primary-expression before ']' token
   20 |             jem = new int[n][];
      |                              ^
a.cc:23:17: error: 'q' was not declared in this scope
   23 |                 q.Answer();
      |                 ^
a.cc:31:13: error: 'move' was not declared in this scope
   31 |             move = new int[m][];
      |             ^~~~
a.cc:31:31: error: expected primary-expression before ']' token
   31 |             move = new int[m][];
      |                               ^
a.cc:66:13: error: 'q' was not declared in this scope
   66 |             q.Enqueue(count == n ? "YES" : "NO");
      |             ^
a.cc: At global scope:
a.cc:71:1: error: expected unqualified-id before 'public'
   71 | public class AnswerCollecter<T>
      | ^~~~~~
a.cc:92:1: error: expected unqualified-id before 'public'
   92 | public static class Scanner
      | ^~~~~~