Language: C++

void main() {
	auto N = readAs!ulong;
	int[] C;
	long res;
	foreach(i; 0..N) {
		auto ip = readAs!(int[]), A = ip[0], B = ip[1];
		res -= B;
		C ~= A + B;	
	}
	C.sort!"a > b"();
	foreach(i; iota(0, N, 2)) {
		res += C[i];
	}
	res.writeln;
}


// ===================================

import std.stdio;
import std.string;
import std.functional;
import std.algorithm;
import std.range;
import std.traits;
import std.math;
import std.container;
import std.bigint;
import std.numeric;
import std.conv;
import std.typecons;
import std.uni;
import std.ascii;
import std.bitmanip;
import core.bitop;

T readAs(T)() if (isBasicType!T) {
	return readln.chomp.to!T;
}
T readAs(T)() if (isArray!T) {
	return readln.split.to!T;
}

T[][] readMatrix(T)(uint height, uint width) if (!isSomeChar!T) {
	auto res = new T[][](height, width);
	foreach(i; 0..height) {
		res[i] = readAs!(T[]);
	}
	return res;
}

T[][] readMatrix(T)(uint height, uint width) if (isSomeChar!T) {
	auto res = new T[][](height, width);
	foreach(i; 0..height) {
		auto s = rs;
		foreach(j; 0..width) res[i][j] = s[j].to!T;
	}
	return res;
}

int ri() {
	return readAs!int;
}

double rd() {
	return readAs!double;
}

string rs() {
	return readln.chomp;
}


Compiler output:
a.cc:5:20: error: too many decimal points in number
    5 |         foreach(i; 0..N) {
      |                    ^~~~
a.cc:46:20: error: too many decimal points in number
   46 |         foreach(i; 0..height) {
      |                    ^~~~~~~~~
a.cc:54:20: error: too many decimal points in number
   54 |         foreach(i; 0..height) {
      |                    ^~~~~~~~~
a.cc:56:28: error: too many decimal points in number
   56 |                 foreach(j; 0..width) res[i][j] = s[j].to!T;
      |                            ^~~~~~~~
a.cc:1:1: error: '::main' must return 'int'
    1 | void main() {
      | ^~~~
a.cc: In function 'int main()':
a.cc:2:18: error: 'readAs' was not declared in this scope
    2 |         auto N = readAs!ulong;
      |                  ^~~~~~
a.cc:3:12: error: structured binding declaration cannot have type 'int'
    3 |         int[] C;
      |            ^~
a.cc:3:12: note: type must be cv-qualified 'auto' or reference to cv-qualified 'auto'
a.cc:3:12: error: empty structured binding declaration
a.cc:3:15: error: expected initializer before 'C'
    3 |         int[] C;
      |               ^
a.cc:5:17: error: 'i' was not declared in this scope
    5 |         foreach(i; 0..N) {
      |                 ^
a.cc:10:9: error: 'C' was not declared in this scope
   10 |         C.sort!"a > b"();
      |         ^
a.cc:11:18: error: expected ')' before ';' token
   11 |         foreach(i; iota(0, N, 2)) {
      |                ~ ^
      |                  )
a.cc:11:20: error: 'iota' was not declared in this scope
   11 |         foreach(i; iota(0, N, 2)) {
      |                    ^~~~
a.cc:14:13: error: request for member 'writeln' in 'res', which is of non-class type 'long int'
   14 |         res.writeln;
      |             ^~~~~~~
a.cc: At global scope:
a.cc:20:1: error: 'import' does not name a type
   20 | import std.stdio;
      | ^~~~~~
a.cc:20:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:21:1: error: 'import' does not name a type
   21 | import std.string;
      | ^~~~~~
a.cc:21:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:22:1: error: 'import' does not name a type
   22 | import std.functional;
      | ^~~~~~
a.cc:22:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:23:1: error: 'import' does not name a type
   23 | import std.algorithm;
      | ^~~~~~
a.cc:23:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:24:1: error: 'import' does not name a type
   24 | import std.range;
      | ^~~~~~
a.cc:24:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:25:1: error: 'import' does not name a type
   25 | import std.traits;
      | ^~~~~~
a.cc:25:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:26:1: error: 'import' does not name a type
   26 | import std.math;
      | ^~~~~~
a.cc:26:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:27:1: error: 'import' does not name a type
   27 | import std.container;
      | ^~~~~~
a.cc:27:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:28:1: error: 'import' does not name a type
   28 | import std.bigint;
      | ^~~~~~
a.cc:28:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:29:1: error: 'import' does not name a type
   29 | import std.numeric;
      | ^~~~~~
a.cc:29:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:30:1: error: 'import' does not name a type
   30 | import std.conv;
      | ^~~~~~
a.cc:30:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:31:1: error: 'import' does not name a type
   31 | import std.typecons;
      | ^~~~~~
a.cc:31:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:32:1: error: 'import' does not name a type
   32 | import std.uni;
      | ^~~~~~
a.cc:32:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:33:1: error: 'import' does not name a type
   33 | import std.ascii;
      | ^~~~~~
a.cc:33:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:34:1: error: 'import' does not name a type
   34 | import std.bitmanip;
      | ^~~~~~
a.cc:34:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:35:1: error: 'import' does not name a type
   35 | import core.bitop;
      | ^~~~~~
a.cc:35:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:37:1: error: 'T' does not name a type
   37 | T readAs(T)() if (isBasicType!T) {
      | ^
a.cc:40:1: error: 'T' does not name a type
   40 | T readAs(T)() if (isArray!T) {
      | ^
a.cc:44:1: error: 'T' does not name a type
   44 | T[][] readMatrix(T)(uint height, uint width) if (!isSomeChar!T) {
      | ^
a.cc:52:1: error: 'T' does not name a type
   52 | T[][] readMatrix(T)(uint height, uint width) if (isSomeChar!T) {
      | ^
a.cc: In function 'int ri()':
a.cc:62:16: error: 'readAs' was not declared in this scope
   62 |         return readAs!int;
      |                ^~~~~~
a.cc:62:22: error: expected ';' before '!' token
   62 |         return readAs!int;
      |                      ^
      |                      ;
a.cc:62:23: error: expected primary-expression before 'int'
   62 |         return readAs!int;
      |                       ^~~
a.cc: In function 'double rd()':
a.cc:66:16: error: 'readAs' was not declared in this scope
   66 |         return readAs!double;
      |                ^~~~~~
a.cc:66:22: error: expected ';' before '!' token
   66 |         return readAs!double;
      |                      ^
      |                      ;
a.cc:66:23: error: expected primary-expression before 'double'
   66 |         return readAs!double;
      |                       ^~~~~~
a.cc: At global scope:
a.cc:69:1: error: 'string' does not name a type
   69 | string rs() {
      | ^~~~~~