[Question]
  [
According to [this XKCD comic](https://xkcd.com/314/), there is a formula to determine whether or not the age gap in a relationship is "creepy". This formula is defined as:
```
(Age/2) + 7
```
being the minimum age of people you can date.
Therefore a relationship is creepy if either of the people in said relationship are younger than the minimum age of the other.
Given the age of two people, can you output whether or not that relationship is creepy? 
### Rules
1. Your program should take two integers as input, the age of both people in the relationship. These can be taken in any reasonable format.
2. Your program must then output a truthy or falsy value describiing whether or not the relationship is "creepy" (Truthy = Creepy).
3. Standard loopholes are not allowed.
4. This puzzle is Code Golf, so the answer with the shortest source code in bytes wins
### Test Cases
```
40, 40    - Not Creepy
18, 21    - Not Creepy
80, 32    - Creepy
15, 50    - Creepy
47, 10000 - Creepy
37, 38    - Not Creepy
22, 18    - Not Creepy
```
  
[Answer]
# NAND gates, 551
[![16-bit creepiness calculator](https://i.stack.imgur.com/bWV7d.png)](https://i.stack.imgur.com/bWV7d.png)
Created with [Logisim](http://www.cburch.com/logisim/)
Same principle as [my other answer](https://codegolf.stackexchange.com/a/141497/73884), but takes 2-byte signed inputs, so it can handle `47, 10000`. Works for ALL test cases!
This is not optimal for the given test cases, as 10000 can be expressed with only 15 of the 16 bits, but it works for any ages in the range [-32768, 32768). Note that any negative age will return `1`.
Inputs on left (no particular order, 1-bit on top). Output in lower right.
[Answer]
# [Python 3](https://docs.python.org/3/), 26 bytes
```
lambda x:max(x)/2+7>min(x)
```
[Try it online!](https://tio.run/nexus/python3#S7ON@Z@TmJuUkqhQYZWbWKFRoalvpG1ul5uZB2T@T8svUqhQyMxTiI42MdBRMDGI1Yk2tNBRMDIEMcyhDAuglLERSMRUR8EUpMYEKGVoAARAtjGQbWwRG2vFpVBQlJlXolGhkwY0W/P/fwA "Python 3 – TIO Nexus")  
The input is a list with both ages
[Answer]
# NAND gates, 274 262
Original:
[![](https://i.stack.imgur.com/fcTpt.png)](https://i.stack.imgur.com/fcTpt.png)
Better:
[![](https://i.stack.imgur.com/Du0k0.png)](https://i.stack.imgur.com/Du0k0.png)
Created with [Logisim](http://www.cburch.com/logisim/)
This takes two inputs on the left as 1-byte signed integers, with the 1-bit at the top. Output is in the lower left; the truthy and falsey here should be obvious.
Works for all test cases except `47, 10000`, so I guess this is technically not a valid answer. However, the [oldest person on (reliable) record](http://www.guinnessworldrecords.com/world-records/oldest-person) was 122, so 8 bits (max 127) will work for any scenario ever possible to this point. I'll post a new answer (or should I edit this one?) when I finish the 16-bit version.
[16-bit version](https://codegolf.stackexchange.com/a/141585/73884) is done!
You'll notice some vertical sections of the circuit. The first one (from the left) determines which input is greater. The next two are multiplexers, sorting the inputs. I then add `11111001` (-7) to the lesser in the fourth section, and I conclude by comparing twice this to the greater input. If it is less, the relationship is creepy. Since I shift the bits to double, I must take into account the unused bit of `lesser-7`. If this is a `1`, then `lesser-7` is negative, and the younger of the two is no older than six. Creepy. I finish with an OR gate, so if either creepiness test returns `1`, the entire circuit does.
If you look closely, you'll see that I used seven one constants (hardcoding the `11111011` and the trailing `0`). I did this because Logisim requires at least one value going in for a logic gate to produce an output. However, each time a constant is used, two NAND gates ensure a `1` value regardless of the constant.
-12 gates thanks to [me](https://codegolf.stackexchange.com/users/73884/scrooble)!
[Answer]
# [05AB1E](https://github.com/Adriandmen/05AB1E), ~~8~~ 6 bytes
```
;7+R‹Z
```
[Try it online!](https://tio.run/##MzBNTDJM/f/f2lw76FHDzqj//6NNDHRMDGIB "05AB1E – Try It Online") or [Try all test](https://tio.run/##MzBNTDJM/V9W6fLf2lw76FHDzqj/lUqH91spKLmkF9sbGhfruqkr2NdmKjkXpaYWVCrpHF6t5JdfogDj/o@ONjHQMTGI1Yk2tNAxMgTSFgY6xkYgvqmOKUjcxFzH0AAIgExjcx1jCyBtZKRjCKINjXUMjWNjAQ "05AB1E – Try It Online")
```
         # Implicit Input: an array of the ages
;        # Divide both ages by 2
 7+      # Add 7 to both ages
   R     # Reverse the order of the ages
         #    this makes the "minimum age" line up with the partner's actual age
    ‹    # Check for less than the input (vectorized)
     Z   # Push largest value in the list
```
[Answer]
# C#, 22 bytes
```
n=>m=>n<m/2+7|m<n/2+7;
```
[Answer]
# C, 29 bytes
```
#define f(a,b)a/2+7>b|b/2+7>a
```
How it works:
* `#define f(a,b)` defines a macro function `f` that takes two untyped arguments.
* `a/2+7>b` checks if the first age divided by two plus seven is larger than the second age.
* `b/2+7>a` checks if the second age divided by two plus seven is larger than the first age.
* If either of the above values are true, return 1 (creepy). Otherwise, return 0 (not creepy).
[Try it online!](https://tio.run/##jZDNCoJAFEb38xQX28zUiPMnSlEt2vcOo2m4SMUMjOrZ7aaEhITezcCZM99lvtg9x3HbektiBAcjAMeFY1HDoUqS8k5kyEHJEQ7R1qrHX9Pn4IsfZAIOUuAMSCPS4ShPKTTHeOkRsjglaZYnkFLLI2Y9tQp20TPqTjtc11VRpLRhQJu90z931s6Q5TBysVlOGXmQz54sr8HCFmPx50awTUfLW32lfZRlyDrYa9iEktMaNqPVjDSf@zOWYoNdgdMmFqvDaQ2Llv@0V9u@AQ)
[Answer]
# JavaScript (ES6), 21 bytes
```
a=>b=>a<b/2+7|b<a/2+7
```
Returns 0 for not creepy, 1 for creepy.
```
f=a=>b=>a<b/2+7|b<a/2+7
console.log(f(40)(40));
console.log(f(18)(21));
console.log(f(80)(32));
console.log(f(15)(50));
console.log(f(47)(10000));
console.log(f(37)(38));
console.log(f(22)(18));
```
[Answer]
# [R](https://www.r-project.org/), ~~26~~ 25 bytes
*-1 byte thanks to @djhurio*
```
any(rev(a<-scan())<a/2+7)
```
[Try it online!](https://tio.run/##K/r/PzGvUqMotUwj0Ua3ODkxT0NT0yZR30jbXPO/kZGCocV/AA)
[Answer]
# [Jelly](https://github.com/DennisMitchell/jelly), 6 bytes
```
H+7>ṚṀ
```
[Try it online!](https://tio.run/##y0rNyan8/99D29zu4c5ZD3c2/P//38RcR8HQAAgA "Jelly – Try It Online")
Seemingly different algorithm than Comrade's.
[Answer]
## [Retina](https://github.com/m-ender/retina), 20 bytes
```
O`.+
^1{7}(1+)¶1\1\1
```
[Try it online!](https://tio.run/nexus/retina#HcbLCYAwEEXR/atDIZpBZvJhpgsXboNkYRdiWxZgYzGEC5czu1ouj2nFUantdfM45dbHiV@@V0qvtcSUGKIUBGLj3WE4wJhid6bMSErCzIhK0X4 "Retina – TIO Nexus")
Input is in unary with a linefeed between the two numbers. Output is `0` (not creepy) or `1` (creepy).
### Explanation
```
O`.+
```
Sort the two numbers, so we know that the larger one is second.
```
^1{7}(1+)¶1\1\1
```
Call the smaller age `a` and the larger age `b`. We first capture `a-7` in group `1`. Then we try to match `2*(a-7)+1` in `b`, which means `b >= 2*(a-7)+1` or `b >= 2*(a-7)` or `b/2+7 > a` which is the criterion for a creepy relationship.
[Answer]
# TI-Basic, ~~20~~ ~~10~~ 9 bytes
```
max(2Ans<14+max(Ans
```
-10 bytes by using a list and part of Timtech's suggestion
-1 byte using lirtosiast's suggestion
Takes in a list of two ages, "{40,42}:prgmNAME"
Returns 1 for 'creepy' and 0 for 'not creepy'.
[Answer]
# Python 3, ~~74~~ 45 bytes
First Code Golf, probably terrible.
29 byte reduction by @Phoenix
```
lambda a,b:0 if(a/2)+7>b or(b/2)+7>a else 1
```
[Answer]
# GNU APL 1.2, 23 bytes
Defines a function that takes two arguments and prints 1 if creepy, 0 if not.
```
∇A f B
(A⌊B)<7+.5×A⌈B
∇
```
### Explanation
`∇` begins and ends the function  
`A f B` is the function header; function is named `f` and takes two arguments, `A` and `B` (functions in APL can be monadic - taking one argument - or dyadic - taking two arguments)  
`A⌊B` is `min(A,B)` and `A⌈B` is `max(A,B)`  
APL is evaluated right-to-left, so parentheses are needed to ensure proper precedence
The other operators are self explanatory.
Code might be golf-able, I'm still new to code-golf.
[Answer]
# JavaScript (ES6), 27 bytes
```
f=a=>b=>b>a?f(b)(a):b>a/2+7
```
No currying (call like `f(a,b)` instead of `f(a)(b)`)
```
f=(a,b)=>b>a?f(b,a):b>a/2+7
```
If `b > a`, swap parameters and retry. Otherwise, check. Currying doesn't save any bytes because of the recursive call.
```
f=a=>b=>b>a?f(b)(a):b>a/2+7
console.log(f(18)(22))
console.log(f(22)(18))
console.log(f(18)(21))
```
[Answer]
# Java, 21 bytes
```
a->b->a/2+7>b|b/2+7>a
```
Absolutely not original.
## Testing
[Try it online!](https://tio.run/nexus/java-openjdk#TU/LasJAFN3nKw6BQNLGaTIqBm3TRaHQTRFciovJS6bEScjcCGLz7XZMYnU29zzu44w81FVD@BFHwVqSJStalZKsFHtaWVZaCq2xTvch53Me4GwBmgTJFF@KPsfWV4PXTZ7JVFAeo8AbLmISJ5NYvPDnRZz8Jn0Vl5WZr9ukNPPjmmMlMxyEVO6GGqn22x1Es9defwqQirY7o1GuSZu9gwqcZ4GPWdD5Nx5GPnh455Hxp/zBn/uYP/TPFj7CwLy7NDXSNLpzzk1L1PW0W/WlqBq4faY@0XLI5f3H2pw05QdWtcRq8xsqXNvJfDgZJnC0o2y/n9gGuxGEBhRM1HV5ckfHY1fgjraHd9gfTZ7XJxtL2N8VIR2oN2S6Buys7vIH "Java (OpenJDK 8) – TIO Nexus")
```
import java.util.function.*;
public class Pcg122520 {
  static IntFunction<IntPredicate> f = a->b->a/2+7>b|b/2+7>a;
  public static void main(String[] args) {
    int[][] tests = {
      {40, 40},
      {18, 21},
      {80, 32},
      {15, 50},
      {47, 10000},
      {37, 38},
      {22, 18}
    };
    for (int[] test: tests) {
      System.out.printf("%d, %d - %s%n", test[0], test[1], f.apply(test[0]).test(test[1]) ? "Creepy" : "Not creepy");
    }
  }
}
```
[Answer]
# Python 3, 31 bytes
`lambda a,b:abs(a-b)>min(a,b)-14`
Not much shorter than the other python submissions, but I found a slightly different way to check for creepiness. I noticed that the acceptable difference between ages is equal to min - 14. This follows from algebraically rearranging the formula.
```
min = (max/2) + 7
min - 7 = max/2
2*min - 14 = max
dif = max - min
max = dif + min
2*min - 14 = dif + min
min - 14 = dif
```
This let me solve without needing two constants, and also without needing to use both max and min, instead using abs(a-b). From a golfing perspective I only got one byte less than @nocturama's solution, but I used a slightly different formula to do it.
[Answer]
# Excel, ~~26~~ 24 Bytes
Cell formula that takes input as numbers from cell range `A1:B1` and output a boolean value representing creepiness to the formula cell
```
=OR(A1/2+7>B1,B1/2+7>A1)
```
**Old Version, 26 Bytes**
```
=MAX(A1:B1)/2+7>MIN(A1:B1)
```
[Answer]
# [Jq 1.5](https://stedolan.github.io/jq/), 11 bytes
```
max/2+7>min
```
[Try it online!](https://tio.run/##HYk7DoAgEAV7T0HvEmHBSOVFjIUlRsEPRAvP7rr4qpl5806DVSCsGqEatAOBupDjZvBvLYj2f20HQiteEcNiXCFEzm58aJ3uBuuuX30geuOWfAwnSRnyskgftpxYjumSMSeWDw "jq – Try It Online")
[Answer]
# TI-Basic, ~~10~~ ~~9~~ 10 bytes
```
2min(Ans)-14≤max(Ans
```
List input from `Ans`, outputs `1` if "creepy" or `0` otherwise.
[Answer]
# [Mathics](http://mathics.github.io/), 16 bytes
```
Max@#/2+7<Min@#&
```
[Try it online!](https://tio.run/##y00sychMLv6fZvvfN7HCQVnfSNvcxjczz0FZ7X9AUWZeiUNadLWJgY6CiYECENTGcsFFDS10FIwM0UUtgGqNjTDUmuoomGKYYGKuo2BoAAQoosZAUWMLiNr/AA "Mathics – Try It Online")
-2 bytes thanks to [@GregMartin](https://codegolf.stackexchange.com/users/56178/greg-martin)
True for not creepy, false for creepy.
```
            (* Argument: A list of integers     *)
Max@#       (* The maximum of the input         *)
 /2+7       (* Divided by 2, plus 7             *)
  <         (* Is less than?                    *)
   Min@#    (* The minimum of the input         *)
    &       (* Anonymous function               *)
```
[Answer]
## SAS, 77 bytes
```
%macro t(a,b);%put%eval(%sysfunc(max(&a,&b))/2+7>%sysfunc(min(&a,&b)));%mend;
```
[Answer]
## Batch, 50 bytes
```
@if %1 gtr %2 %0 %2 %1
@cmd/cset/a"%1*2-14-%2>>31
```
Outputs `-1` for creepy, `0` for not creepy.
Since Batch only has integer arithmetic I have to work in units of half years.
[Answer]
# [Perl 6](https://perl6.org), 15 bytes
```
{.max/2+7>.min}
```
[Try it](https://tio.run/nexus/perl6#ZY7LaoNAFIb38xT/IlSto@MtjVQSCt131aUQUp2C4GWaGUtC8In6Fn0xezS9UDybw3znY/6/1xLvd36RseaMm6IrJbbjxW8OJxG5m53fVO0w0unBSG2wRV21UtsOCer@woCVIOhrVVfGFsj1LSzPmrdwMrq7nx@rwC@65sUWeekKh2MVQr7BejxKqc4WvfdsYD31eKaIjKn60MKd8zL22h2/o70d7LxqVW94Lk9KFkaWPC@lLhxMRSqNqb09K5Ty62By2DAmAUcSgMbDU2dwzWdhyhGFC5ySHUdX/GOuOdbBP5RsOMKA5g/FhOJ08V8UkbnAXw "Perl 6 – TIO Nexus")
## Expanded
```
{ # bare block lambda with implicit parameter ｢$_｣
  # (input is a List)
  .max / 2 + 7
  >
  .min
}
```
[Answer]
# [Crystal](https://crystal-lang.org/), 44  27 bytes
-17 from looking at [daniero](https://codegolf.stackexchange.com/a/122839/69490)'s answer in Ruby.
```
def a(a)7+a.max/2>a.min end
```
[Try it online!](https://tio.run/nexus/crystal#@5@SmqaQqJGoaa6dqJebWKFvZAekM/MUUvNSuApKS4qBktEmBjomBrGacL6hhY6RIRLfwkDH2AhZ3lTHFFm9ibmOoQEQIAkZm@sYWyDxjYx0DIH8//8B "Crystal – TIO Nexus")
[Answer]
# Python 3 - ~~32~~ 27 bytes
Unable to comment, but I got a slightly shorter answer than the other Python 3 solution:
```
lambda *a:min(a)<max(a)/2+7
```
-5 thanks to @Cyoce!
[Answer]
# **FORTH 96 Bytes**
```
: C 2DUP > -1 = IF SWAP THEN 2 /  7 +  SWAP > -1 = IF ."  CREEPY " ELSE ." NOT CREEPY " THEN ;
```
**Output:**
```
40 40 c NOT CREEPY  ok
18 21 c
18 21 c NOT CREEPY  ok
80 32 c
80 32 c  CREEPY  ok
15 50 c
15 50 c  CREEPY  ok
47 10000 c
47 10000 c  CREEPY  ok
37 38 c
37 38 c NOT CREEPY  ok
22 18 c
22 18 c NOT CREEPY  ok
```
[Answer]
# [Thunno 2](https://github.com/Thunno/Thunno2) `G`, 5 [bytes](https://github.com/Thunno/Thunno2/blob/main/docs/codepage.md)
```
½7+r<
```
[Attempt This Online!](https://ato.pxeger.com/run?1=m728JKM0Ly_faGm0krtS7IKlpSVpuhbLDu011y6yWVKclFwMFVqwzNBUR8HUAMIDAA)
Port of Riley's 05AB1E answer.
#### Explanation
```
½7+r<  # Implicit input
½      # Halve each value
 7+    # Add seven to each
   r   # Reverse the list
    <  # Vectorised less than
       # Get the maximum
       # Implicit output
```
[Answer]
# [K (oK)](https://github.com/JohnEarnest/ok), 16 bytes
```
{(x&y)<7+-2!x|y}
```
[Try it online!](https://tio.run/##y9bNz/7/v1qjQq1S08ZcW9dIsaKmsvZ/goGVCrqgnoaJgYKJgSYXdklDUwVTA83/AA "K (oK) – Try It Online")
[Answer]
# [Uiua](https://uiua.org), 8 [bytes](https://codegolf.stackexchange.com/a/265917/97916)
```
<+7÷2⊃↥↧
```
[Try it online!](https://www.uiua.org/pad?src=ZiDihpAgPCs3w7cy4oqD4oal4oanCgpmIDQwIDQwCmYgMTggMjEKZiA4MCAzMgpmIDE1IDUwCmYgNDcgMTAwMDAKZiAzNyAzOApmIDIyIDE4CmYgMTMgMTMKZiAyMSAyOQo=)
```
<+7÷2⊃↥↧    input: two ages as two separate stack items
     ⊃↥↧    push max and min of the two ages
 +7÷2       max / 2 + 7
<           is greater than min?
```
[Answer]
# [Nekomata](https://github.com/AlephAlpha/Nekomata) + `-e`, 5 bytes
```
Ṁä7+≥
```
[Attempt This Online!](https://ato.pxeger.com/run?1=m70iLzU7PzexJHFNtJJurpKOgpJuqlLsgqWlJWm6Fqse7mw4vMRc-1Hn0iXFScnFUOEFN62iTQx0TAxiuaINLXSMDIG0hYGOsRGIb6pjChI3MdcxNAACINPYXMfYAkgbGekYWsRCjAAA)
Returns `True` for not creepy, `False` for creepy.
```
Ṁ        Get the maximum of the input
 ä       Divide it by 2
  7+     Add 7
    ≥    Is every element of the input greater than or equal to that?
```
]