Language: C++

#include <iostream>
using namespace std;
int main()
{
  int a,b,c,d,e,f;
  cin>>a>>b>>c>>d>>e>>f;
  if (|a-b|>18 || |a-c|>18){
    cout<<":(";
  }else if (|a-d|>18 || |a-e|>18){
    cout<<":(";
  }else if (|a-e|>18 || |b-c|>18){
    cout<<":(";
  }else if (|b-d|>18 || |b-e|>18){
    cout<<":(";
  }else if (|b-f|>18 || |c-d|>18){
    cout<<":(";
  }else if (|c-e|>18 || |c-f|>18){
    cout<<":(";
  }else if (|d-e|>18 || |d-f|>18){
    cout<<":(";
  }else if (|e-f|>18){
    cout<<":(";
  }else {
    cout<<"Yay!";
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:7: error: expected primary-expression before '|' token
    7 |   if (|a-b|>18 || |a-c|>18){
      |       ^
a.cc:7:12: error: expected primary-expression before '>' token
    7 |   if (|a-b|>18 || |a-c|>18){
      |            ^
a.cc:7:19: error: expected primary-expression before '|' token
    7 |   if (|a-b|>18 || |a-c|>18){
      |                   ^
a.cc:7:24: error: expected primary-expression before '>' token
    7 |   if (|a-b|>18 || |a-c|>18){
      |                        ^
a.cc:9:13: error: expected primary-expression before '|' token
    9 |   }else if (|a-d|>18 || |a-e|>18){
      |             ^
a.cc:9:18: error: expected primary-expression before '>' token
    9 |   }else if (|a-d|>18 || |a-e|>18){
      |                  ^
a.cc:9:25: error: expected primary-expression before '|' token
    9 |   }else if (|a-d|>18 || |a-e|>18){
      |                         ^
a.cc:9:30: error: expected primary-expression before '>' token
    9 |   }else if (|a-d|>18 || |a-e|>18){
      |                              ^
a.cc:11:13: error: expected primary-expression before '|' token
   11 |   }else if (|a-e|>18 || |b-c|>18){
      |             ^
a.cc:11:18: error: expected primary-expression before '>' token
   11 |   }else if (|a-e|>18 || |b-c|>18){
      |                  ^
a.cc:11:25: error: expected primary-expression before '|' token
   11 |   }else if (|a-e|>18 || |b-c|>18){
      |                         ^
a.cc:11:30: error: expected primary-expression before '>' token
   11 |   }else if (|a-e|>18 || |b-c|>18){
      |                              ^
a.cc:13:13: error: expected primary-expression before '|' token
   13 |   }else if (|b-d|>18 || |b-e|>18){
      |             ^
a.cc:13:18: error: expected primary-expression before '>' token
   13 |   }else if (|b-d|>18 || |b-e|>18){
      |                  ^
a.cc:13:25: error: expected primary-expression before '|' token
   13 |   }else if (|b-d|>18 || |b-e|>18){
      |                         ^
a.cc:13:30: error: expected primary-expression before '>' token
   13 |   }else if (|b-d|>18 || |b-e|>18){
      |                              ^
a.cc:15:13: error: expected primary-expression before '|' token
   15 |   }else if (|b-f|>18 || |c-d|>18){
      |             ^
a.cc:15:18: error: expected primary-expression before '>' token
   15 |   }else if (|b-f|>18 || |c-d|>18){
      |                  ^
a.cc:15:25: error: expected primary-expression before '|' token
   15 |   }else if (|b-f|>18 || |c-d|>18){
      |                         ^
a.cc:15:30: error: expected primary-expression before '>' token
   15 |   }else if (|b-f|>18 || |c-d|>18){
      |                              ^
a.cc:17:13: error: expected primary-expression before '|' token
   17 |   }else if (|c-e|>18 || |c-f|>18){
      |             ^
a.cc:17:18: error: expected primary-expression before '>' token
   17 |   }else if (|c-e|>18 || |c-f|>18){
      |                  ^
a.cc:17:25: error: expected primary-expression before '|' token
   17 |   }else if (|c-e|>18 || |c-f|>18){
      |                         ^
a.cc:17:30: error: expected primary-expression before '>' token
   17 |   }else if (|c-e|>18 || |c-f|>18){
      |                              ^
a.cc:19:13: error: expected primary-expression before '|' token
   19 |   }else if (|d-e|>18 || |d-f|>18){
      |             ^
a.cc:19:18: error: expected primary-expression before '>' token
   19 |   }else if (|d-e|>18 || |d-f|>18){
      |                  ^
a.cc:19:25: error: expected primary-expression before '|' token
   19 |   }else if (|d-e|>18 || |d-f|>18){
      |                         ^
a.cc:19:30: error: expected primary-expression before '>' token
   19 |   }else if (|d-e|>18 || |d-f|>18){
      |                              ^
a.cc:21:13: error: expected primary-expression before '|' token
   21 |   }else if (|e-f|>18){
      |             ^
a.cc:21:18: error: expected primary-expression before '>' token
   21 |   }else if (|e-f|>18){
      |                  ^