Language: C++

using System;
using System.Collections.Generic;
using System.Linq;

namespace Aizu
{
    class Program
    {
        static void Main(string[] args)
        {
            var n = int.Parse(Console.ReadLine());
            var data = Console.ReadLine().Split(' ').Select(d => int.Parse(d)).ToList<int>();

            int changeCount = 0;
            int num = 1;
            for(int i = n - 1;  -1 < i; i--)
            {
                for(int j = 0; j < i; j++)
                {
                    if (data[j + 1] < data[j])
                    {
                        var temp = data[j];
                        data[j] = data[j + 1];
                        data[j + 1] = temp;
                        changeCount++;
                    }
                }
                num++;
            }

            Console.WriteLine(string.Join(" ", (string[])data.Select(d => d.ToString()).ToArray()));
            Console.WriteLine(changeCount);
        }
    }

}



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:9:26: error: 'string' has not been declared
    9 |         static void Main(string[] args)
      |                          ^~~~~~
a.cc:9:35: error: expected ',' or '...' before 'args'
    9 |         static void Main(string[] args)
      |                                   ^~~~
a.cc:34:6: error: expected ';' after class definition
   34 |     }
      |      ^
      |      ;
a.cc: In static member function 'static void Aizu::Program::Main(int*)':
a.cc:11:13: error: 'var' was not declared in this scope
   11 |             var n = int.Parse(Console.ReadLine());
      |             ^~~
a.cc:12:17: error: expected ';' before 'data'
   12 |             var data = Console.ReadLine().Split(' ').Select(d => int.Parse(d)).ToList<int>();
      |                 ^~~~
a.cc:16:25: error: 'n' was not declared in this scope
   16 |             for(int i = n - 1;  -1 < i; i--)
      |                         ^
a.cc:20:25: error: 'data' was not declared in this scope
   20 |                     if (data[j + 1] < data[j])
      |                         ^~~~
a.cc:22:29: error: expected ';' before 'temp'
   22 |                         var temp = data[j];
      |                             ^~~~
a.cc:24:39: error: 'temp' was not declared in this scope
   24 |                         data[j + 1] = temp;
      |                                       ^~~~
a.cc:31:13: error: 'Console' was not declared in this scope
   31 |             Console.WriteLine(string.Join(" ", (string[])data.Select(d => d.ToString()).ToArray()));
      |             ^~~~~~~
a.cc:31:31: error: 'string' was not declared in this scope
   31 |             Console.WriteLine(string.Join(" ", (string[])data.Select(d => d.ToString()).ToArray()));
      |                               ^~~~~~
a.cc:31:56: error: expected primary-expression before ']' token
   31 |             Console.WriteLine(string.Join(" ", (string[])data.Select(d => d.ToString()).ToArray()));
      |                                                        ^