Language: C++

#include <bits/stdc++.h>

using namespace std;

int main () {
    ios_base::sync_with_stdio(false);
    cin.tie(0);
    int n, r = 0; cin >> n;
    vector<ll> a(n);
    for (int i = 0; i < n; i++) {
        cin >> a[i];
        for (int j = i - 1; j >= 1; j--) {
            if (a[j] == a[i]) {
                continue;
            }
            for (int k = j - 1; k >= 0; k--) {
                if (a[k] == a[i] || a[k] == a[j]) {
                    continue;
                }
                if (a[i] + a[j] + a[k] > 2 * max(a[i], max(a[j], a[k]))) {
                    r++;
                }
            }
        }
    }
    cout << r << endl;
    return 0;
}



Compiler output:
a.cc: In function 'int main()':
a.cc:9:12: error: 'll' was not declared in this scope
    9 |     vector<ll> a(n);
      |            ^~
a.cc:9:14: error: template argument 1 is invalid
    9 |     vector<ll> a(n);
      |              ^
a.cc:9:14: error: template argument 2 is invalid
a.cc:11:17: error: invalid types 'int[int]' for array subscript
   11 |         cin >> a[i];
      |                 ^
a.cc:13:18: error: invalid types 'int[int]' for array subscript
   13 |             if (a[j] == a[i]) {
      |                  ^
a.cc:13:26: error: invalid types 'int[int]' for array subscript
   13 |             if (a[j] == a[i]) {
      |                          ^
a.cc:17:22: error: invalid types 'int[int]' for array subscript
   17 |                 if (a[k] == a[i] || a[k] == a[j]) {
      |                      ^
a.cc:17:30: error: invalid types 'int[int]' for array subscript
   17 |                 if (a[k] == a[i] || a[k] == a[j]) {
      |                              ^
a.cc:17:38: error: invalid types 'int[int]' for array subscript
   17 |                 if (a[k] == a[i] || a[k] == a[j]) {
      |                                      ^
a.cc:17:46: error: invalid types 'int[int]' for array subscript
   17 |                 if (a[k] == a[i] || a[k] == a[j]) {
      |                                              ^
a.cc:20:22: error: invalid types 'int[int]' for array subscript
   20 |                 if (a[i] + a[j] + a[k] > 2 * max(a[i], max(a[j], a[k]))) {
      |                      ^
a.cc:20:29: error: invalid types 'int[int]' for array subscript
   20 |                 if (a[i] + a[j] + a[k] > 2 * max(a[i], max(a[j], a[k]))) {
      |                             ^
a.cc:20:36: error: invalid types 'int[int]' for array subscript
   20 |                 if (a[i] + a[j] + a[k] > 2 * max(a[i], max(a[j], a[k]))) {
      |                                    ^
a.cc:20:51: error: invalid types 'int[int]' for array subscript
   20 |                 if (a[i] + a[j] + a[k] > 2 * max(a[i], max(a[j], a[k]))) {
      |                                                   ^
a.cc:20:61: error: invalid types 'int[int]' for array subscript
   20 |                 if (a[i] + a[j] + a[k] > 2 * max(a[i], max(a[j], a[k]))) {
      |                                                             ^
a.cc:20:67: error: invalid types 'int[int]' for array subscript
   20 |                 if (a[i] + a[j] + a[k] > 2 * max(a[i], max(a[j], a[k]))) {
      |                                                                   ^