[Question]
  [
An *insignificant array* is an array of positive integers, where the absolute differences between consecutive elements are all smaller than or equal to **1**.
For example, the following array is insignificant:
```
[1, 2, 3, 4, 3, 4, 5, 5, 5, 4]
```
Because the corresponding (absolute) differences are:
```
[1, 1, 1, 1, 1, 1, 0, 0, 1]
```
Which are all smaller than or equal to **1**.
---
Your task is to determine whether a given array of integers is insignificant.
* You may assume that the array always contains at least two elements.
* [Standard input and output rules](https://codegolf.meta.stackexchange.com/questions/2419/default-for-code-golf-program-function-or-snippet/2422#2422) apply. You may take input (and output) in any reasonable format.
* [Default Loopholes](https://codegolf.meta.stackexchange.com/questions/1061/loopholes-that-are-forbidden-by-default) are forbidden.
* The truthy / falsy values have to be distinct and consistent.
* This is [code-golf](/questions/tagged/code-golf "show questions tagged 'code-golf'"), so shortest answer in bytes wins.
# Test cases
```
Input -> Output
[1, 2, 3, 4, 3, 4, 5, 5, 5, 4] -> true
[1, 2, 3, 4, 5, 6, 7, 8, 9, 8] -> true
[3, 3, 3, 3, 3, 3, 3]          -> true
[3, 4, 4, 4, 3, 3, 3, 4, 4, 4] -> true
[1, 2, 3, 4]                   -> true 
[5, 4, 3, 2]                   -> true 
[1, 3, 5, 7, 9, 7, 5, 3, 1]    -> false
[1, 1, 1, 2, 3, 4, 5, 6, 19]   -> false
[3, 4, 5, 6, 7, 8, 7, 5]       -> false
[1, 2, 4, 10, 18, 10, 100]     -> false
[10, 20, 30, 30, 30]           -> false
```
I used the values `true` and `false`.
  
[Answer]
# [Jelly](https://github.com/DennisMitchell/jelly), 3 bytes
```
IỊẠ
```
**[Try it online!](https://tio.run/##y0rNyan8/9/z4e6uh7sW/P//P9pQR8FIR8FYR8EERprCkEksAA "Jelly – Try It Online")**
# How?
Just the perfect challenge for Jelly.
```
IỊẠ   Full program.
I     Increments; Get the difference between consecutive elements.
 Ị    Insignificant; return abs(number) ≤ 1.
  Ạ   All; returns 1 if all the elements are truthy, 0 otherwise.
```
[Answer]
# JavaScript (ES7), ~~33~~ 29 bytes
*Saved 4 bytes thanks to @JohanKarlsson*
```
a=>!a.some(v=>(a-(a=v))**2>1)
```
### How?
When coerced to `Number`, arrays of at least two elements are evaluated to `NaN`. By re-using the input ***a*** as the variable holding the previous value, the first iteration of ***some()*** always results in ***([v0, v1, ...] - a[0]) \*\* 2 = NaN***, no matter the value of ***a[0]***. So, the first test is always falsy and the actual comparisons start at the 2nd iteration, just as they're meant to.
### Test cases
```
let f =
(a,p)=>!a.some(v=>(p-(p=v))**2>1)
console.log(f([1, 2, 3, 4, 3, 4, 5, 5, 5, 4])) // true
console.log(f([1, 2, 3, 4, 5, 6, 7, 8, 9, 8])) // true
console.log(f([3, 3, 3, 3, 3, 3, 3]         )) // true
console.log(f([3, 4, 4, 4, 3, 3, 3, 4, 4, 4])) // true
console.log(f([1, 2, 3, 4]                  )) // true
console.log(f([5, 4, 3, 2]                  )) // true
console.log(f([1, 3, 5, 7, 9, 7, 5, 3, 1]   )) // false
console.log(f([1, 1, 1, 2, 3, 4, 5, 6, 19]  )) // false
console.log(f([3, 4, 5, 6, 7, 8, 7, 5]      )) // false
console.log(f([1, 2, 4, 10, 18, 10, 100]    )) // false
console.log(f([10, 20, 30, 30, 30]          )) // false
```
[Answer]
# [Python 3](https://docs.python.org/3/), 40 bytes
```
f=lambda n,*t:t==()or-2<n-t[0]<=1==f(*t)
```
[Try it online!](https://tio.run/##hZHbCoMwDIav51MEdmNHBVt1U7FPIr1wbGWCq9J14J7edfUwD4OVPwmkH39I27z0rZZB1wlWFffzpQCJDzrVjLmoVh7NpKdzn2eMMCbcg0adqBW0UEpwHWeXEwwUQ4AhHHM0KuSA96DV87rizN0RwwlDjCExec4FFlqIw3QWXDhqQofO77kzm7UfGDAaregfkFgqsgskNke2Q/gAiqJ6DKN7rRYnCV@C21f5mPLv6JkjtSzxTcRD9X2@AU2fmgim4MtletBBKTSqlNo1X9si1L0B "Python 3 – Try It Online")
[Answer]
## Mathematica, 24 bytes
```
Max@Abs@Differences@#<2&
```
[Answer]
# [Haskell](https://www.haskell.org/), ~~34~~ 33 bytes
```
all((<2).abs).(zipWith(-)=<<tail)
```
[Try it online!](https://tio.run/##dVDNCoJAGLz7FINEGKzgrpYa2LFTt7rFFisqSmbhz6Gnt83afkyX@T6X2WFkJhXVKc7ztk0MsQyX5SxgK0OY4ezAptPEeDBagmNAV1Z7FlmBANEFGkwTVXpp8gi3LJZ7VzaxhmuZFTUmSLCnBIzAJnDUnis4fFQpXxcELoFH4Mv9q7Q72Q841OkrHYW3@MWM/f1jNeQ4V15sSNfU27rcFNB1DX/drEVe/ZVjd2HdLqbb3SVDOfq6J3oFUZ8PxP0u72HJgYGoUkgtOd7ra1m9QiTJ5Njv4e0d "Haskell – Try It Online") *-1 byte thanks to [@user1472751](https://codegolf.stackexchange.com/users/65900/user1472751)*
---
The point-free solution is ~~one~~ ~~two~~ again only one byte (*thanks to -1 byte from [@Dennis](https://codegolf.stackexchange.com/users/12012/dennis)*) shorter than the recursive approach:
```
f(a:b:r)=2>(a-b)^2&&f(b:r)
f _=1>0
```
[Try it online!](https://tio.run/##dVDNCoJAGLz7FEOEGKzg@pMp6LFTt7rFEisqSabhz6Gnt81aK9Nlvs9ldhiZOfP6kuR516Ua9yO/WgVmyKNa43q0UtVUe1JKilNAQ6O78qxAgLiEAl1HfS7bPMY9S8Q@VG2i4FZlRYMlUhwpgUlgEdhyOxI2m1WK1zWBS7Ah8MT@VVq97AcM8oyVtsQgfjNzf/9YTTk60suc0rXNvql2BRYLBX/dbHle/5Vj9WHdPqbb3wVDGca6F0YFUY9NxP0u72nJgImoQkgNMZv31zBGhQjSFGMNw7oH "Haskell – Try It Online")
[Answer]
# [Octave](https://www.gnu.org/software/octave/), 21 bytes
```
@(x)all(diff(x).^2<2)
```
Anonymous function that inputs a numeric vector and ouputs `1` if insignificant or `0` otherwise.
[**Try it online!**](https://tio.run/##dZFhC4MgEIa/9yvuY4FIaq1iC/Y/RoNoCYHUYDUGY7/d3SzbrCbvncf5qK/YVX15r7XMKaX66D@CUin/0kiJJT3zAw90016H/gY5POHECHACgkBkc2wVFR58h0Pi6o5AQiAlkGF2SWEwRysgspqZqfPvUrcf2718xQtjLzHGElNjh62wUYsXsWzL6O9rPyduWUSMhRjpNIfhgsImxxBzFPDae1WtlBxaXxIYfyXQbw "Octave – Try It Online")
[Answer]
# [Pyth](https://github.com/isaacg1/pyth), 6 bytes
```
._MI.+
```
**[Verify all the test cases.](https://pyth.herokuapp.com/?code=._MI.%2B&input=%5B1%2C+2%2C+3%2C+4%2C+3%2C+4%2C+5%2C+5%2C+5%2C+4%5D&test_suite=1&test_suite_input=%5B1%2C+2%2C+3%2C+4%2C+3%2C+4%2C+5%2C+5%2C+5%2C+4%5D%0A%5B1%2C+2%2C+3%2C+4%2C+5%2C+6%2C+7%2C+8%2C+9%2C+8%5D%0A%5B3%2C+3%2C+3%2C+3%2C+3%2C+3%2C+3%5D%0A%5B3%2C+4%2C+4%2C+4%2C+3%2C+3%2C+3%2C+4%2C+4%2C+4%5D%0A%5B1%2C+2%2C+3%2C+4%5D%0A%5B5%2C+4%2C+3%2C+2%5D%0A%5B1%2C+3%2C+5%2C+7%2C+9%2C+7%2C+5%2C+3%2C+1%5D%0A%5B1%2C+1%2C+1%2C+2%2C+3%2C+4%2C+5%2C+6%2C+19%5D%0A%5B3%2C+4%2C+5%2C+6%2C+7%2C+8%2C+7%2C+5%5D%0A%5B1%2C+2%2C+4%2C+10%2C+18%2C+10%2C+100%5D%0A%5B10%2C+20%2C+30%2C+30%2C+30%5D&debug=0)**
---
# [Pyth](https://github.com/isaacg1/pyth), 8 bytes
```
.A<R2aVt
```
[Try it online!](https://tio.run/##K6gsyfj/X8/RJsgoMazk//9oQx0FIx0FYx0FExhpCkMmsQA "Pyth – Try It Online")
# Explanation
```
._MI.+   Full program.
    .+   Deltas.
   I     Is invariant under...
._M      Mapping with Sign. 0 if n == 0, -1 if n < 0, 1 if n > 0.
```
---
[Answer]
# [Python 2](https://docs.python.org/2/), 35 bytes
```
x=input()
while-2<x.pop(0)-x[0]<2:1
```
Exists with status code **1** for insignificant arrays, with status code **0** otherwise.
[Try it online!](https://tio.run/##fZDBboMwDIbPzVNYXQ@tlCISoC1btp1222HabUI5ZJCOSFVAJdXo0zOWFAqsWvTbkexPv@N8iipvUmHgCZSu1JdWe5UKbbzyDIyB19SPSpcns1yh71wd5Jqy2iuLcumv1nXic0bvSeMh14SjFNkDZAWalWeTF5reMmUwX7y/vL1@zNFMpnkBi2eUFVo2CcFAMQQYwi5HnUIOd2COJ4lGVNvZYNhi2GGI23ylAouMxKE/Ayrs1IOXyq2JA4uJF6Ak6mzovxixTGSfHdsc2QrhDtuLQ@WGOk2WJTEfYn//4deQ90OvbtSSxG9jd7l9n0@wtkrbCPrgoxUc9gM "Bash – Try It Online")
[Answer]
# [Husk](https://github.com/barbuz/Husk), 4 bytes
```
ΛεẊ-
```
[Try it online!](https://tio.run/##yygtzv7//9zsc1sf7urS/f//f7ShjpGOsY4JGJuCoUksAA "Husk – Try It Online")
Explanation:
```
ΛεẊ- 2-function composition
Λ    (x -> y):f -> [x]:x -> TNum: Check if f returns a truthy result for all elements of x
 ε    f: TNum:x -> TNum: Check if abs(x) <= 1 (shamelessly stolen from Jelly)
  Ẋ   x: (x -> x -> y):f -> [x]:x -> [y]: reduce each overlapping pair of x by f
   -   f: TNum:x -> TNum:y -> TNum: y - x
```
[Answer]
# [Japt](https://github.com/ETHproductions/japt), 6 bytes
```
äa e<2
```
[Try it online!](https://ethproductions.github.io/japt/?v=1.4.5&code=5GEgZTwy&input=WzEsIDIsIDMsIDQsIDMsIDQsIDUsIDUsIDUsIDRd)
## Explanation
```
ä        Get all pairs of elements
 a       Take absolute difference of each pair
         This results in the deltas of the array
   e     Check if every element...
    <2   Is less than 2
```
[Answer]
# APL, 13 bytes
```
{×/(|2-/⍵)<2}
```
First APL answer \o/
Note: I am a bot owned by Hyper Neutrino. I exist mainly for chat testing.
# Explanation
```
{×/(|2-/⍵)<2}
{           }  Function; right argument is ⍵
   (     )     Bracketed Expression
       /       Reduce
     2         Every pair (two elements) of
        ⍵      ⍵
      -        Using subtraction
    |          Magnitude (Absolute Value)
          <2   For each element, is it less than two?
  /            Reduce over
 ×             Multiplication (Product) (All)
```
[Answer]
# [05AB1E](https://github.com/Adriandmen/05AB1E), 5 bytes
```
¥Ä2‹P
```
[Try it online!](https://tio.run/##MzBNTDJM/f//0NLDLUaPGnYG/P8fbaijYKSjYKyjYAIjTWHIJBYA "05AB1E – Try It Online")
**Explanation**
```
¥        # calculate deltas
 Ä       # absolute values
  2‹     # smaller than 2
    P    # product
```
[Answer]
# [Proton](https://github.com/alexander-liao/proton), 41 bytes
```
a=>all(-2<a[i]-a[i+1]<2for i:0..len(a)-1)
```
[Try it online!](https://tio.run/##NcRBCoAgEADAr@xxlzTS7BLWR8TDHgoEURH/v3URhmm9jlqk9VQGovB1c86oreeQov5bTPT2rR3Sua1rfgoyaUNCGIwCq2BX4ObH5CKRfA "Proton – Try It Online")
-16 bytes thanks to Mr. Xcoder  
-2 bytes  
-6 bytes thanks to Mr. Xcoder 
[Answer]
# [Ohm v2](https://github.com/MiningPotatoes/Ohm), 4 bytes
```
Δ2<Å
```
[Try it online!](https://tio.run/##y8/INfr//9wUI5vDrf//RxvqKBjpKBjrKJjoKJjqKJjpKJjrKFjoKFgCyVgA "Ohm v2 – Try It Online")
# How?
```
Δ2<Å   ~ Full program.
Δ      ~ Absolute deltas.
 2<    ~ Is smaller than 2?
   Å   ~ Check if all elements are truthy.
```
[Answer]
# [C# (.NET Core)](https://www.microsoft.com/net/core/platform), ~~51~~ ~~45~~ 44 + 18 bytes
*-1 byte thanks to [Jeppe Stig Nielsen](https://codegolf.stackexchange.com/users/8727/jeppe-stig-nielsen)*
```
a=>a.Zip(a.Skip(1),(x,y)=>x-y).All(x=>x*x<4)
```
Byte count also includes:
```
using System.Linq;
```
[Try it online!](https://tio.run/##ZU9RT8IwEH5ef8XJA7SmNIxNgchIiIlPmhhHQqLxoY4ijaXDteiI4bdjuzEjmtz1Lt93993XzHSzvBAHzdfCbHgmIN0ZK9bsVup39IWCTHFjYIoC1wfGcisz@MjlAu641Jg40BPBzVZnY6nt0zOFlzxXE1hCcuDJhLNHucGcpW@uhITiku5IMim7O8KmSuHS9eflOCYHp3LlpYwtpH4FqTdbWwGfK6kExhUACVzn2uRKsAfBF86lwITAWQJ6qxS02/WeB1ot7y4Imvl5Ia2oFpa1Fks3SlrcoR0KHegQNl@JQuASkgmURwWWCiUyW4Puf@yeF8bNsFkh1@4yYbN8WhR853vvdo9c7A8hhT6FiELcvBdNxOg36YBLCgMKQwoj96KoYk4C1aNxoxY1y/GpGrpoJvoejSr1QaU7qHqHhJ6p44@HcIT@W/J7xwuOCXsuh8fa6yFf@y6jn/wG "C# (.NET Core) – Try It Online")
Explanation:
```
a =>                      // Take an array of integers as input
    a.Zip(                // Combine each element with corresponding one from:
        a.Skip(1),        //     the input array without first element
        (x, y) => x - y   //     get their difference
    )
    .All(x => x * x < 4)  // Check if all differences are less than 2
                          // (We only care about 0 and 1, and so happens that when they're squared, it works like Abs! Magic!)
```
[Answer]
# [Perl 6](https://perl6.org), 25 bytes
```
{?(2>all(.[]Z-.skip)>-2)}
```
[Try it online!](https://tio.run/##fVHLTsMwELznK0aih1ZyKj/zUCH8B5UFPTQSIogqgQOq@u1hs46bpCCys2trPJnNOqdj22T9@zdWNR7Qnx/Xujo0zXq790/ptnt7PW2qVG8u/S65ezmfk70S0AJGwMbqIqxHWuGz/TouZXSUCeQChUBJdSYzrFnA4/rMZTbiqhyZP5vOTG7dkOxdNNL/6xSLHH97ydUxo/yoqw9NF/oG3IysSr/Q/b6OwdJPfSc/zVIlKYtxldLf6ojWlOaafjlH0F0uSXcY/vB69bxB/dHiXkHDwHI6DluJiXbIkKNAiWKgDWYRCMsRKN7PXh@2jk91YA0Z5mSW02qgAjnE1E2V0Tf2JnH0tDQ83QNXKZmVNDjNG1Dt@h8 "Perl 6 – Try It Online")
This should be pretty readable. The only less obvious thing here is that the zip operator `Z` will stop zipping when the shorter list is exhausted (we remove the first element of the list at the right) and that the empty subscript `.[]`, so called Zen slice, gives the whole list. `.skip` returns the list without the first element.
[Answer]
# [R](https://www.r-project.org/), ~~30~~ 26 bytes
```
cat(all(diff(scan())^2<2))
```
[Try it online!](https://tio.run/##K/qfZvs/rTQvuSQzP08jUTMxJ0cjJTMtDciMM7Ix0vyfppGsYaqjYKKjYKyjYKSpyQUSMAYLAIXNdBTMdRQswKSppqbCfwA "R – Try It Online")
[Answer]
# [PowerShell](https://github.com/TryItOnline/TioSetup/wiki/Powershell), 62 bytes
```
param($a)$l=$a[0];($a|?{$_-$l-in1..-1;$l=$_}).count-eq$a.count
```
[Try it online!](https://tio.run/##K8gvTy0qzkjNyfn/vyCxKDFXQyVRUyXHViUx2iDWGsipsa9WiddVydHNzDPU09M1tAZJxtdq6iXnl@aV6KYWqiRCmP///3fQMNRRMNZRMNVRMNdRsASTpmARQ00A "PowerShell – Try It Online")
PowerShell doesn't have a `.map` or `.some` or similar command, so here we're individually checking each delta.
We take input `$a` and set `$l` equal to the first element. Then we loop through `$a` and take out each element where `|?{...}` the difference `$_-$l` is `-in` the range `1,0,-1`. We then set `$l` equal to the current element. So now we have a collection of elements where the delta between their previous neighbor is 1. We take the `.count` of that and check whether it's `-eq`ual to the `.count` of the array as a whole. If it is, then every delta is 1 or less, so it's an insignificant array. That Boolean result is left on the pipeline, and output is implicit.
[Answer]
# Factor, ~~48~~ 33 bytes
Saved 15 bytes thanks to @chunes!
```
[ dup rest v- vabs supremum 2 < ]
```
[Try it online!](https://tio.run/##XY6xDsIwDET3fMX9QFsKdABVbGVlQEyIIYQgliqRnXSgCr8empIuyDrZOvvp/OZXVNLhgE9VPqVyhgpSaFt0p6O4nLs9rCTWBOmdKTxrkRYLwsaT0hlcKDFiRI01GuwQ8ryZVGM1KVVyG2xnNyDEKx7egjQ7DAUGeWewt6R7308XLW6xlxalmMMrY131i8zt/5P4BQ "Zsh – Try It Online") (results are at the bottom)
`dup rest` makes a copy of the inputted sequence without the first element. `v-` subtracts that from the original sequence (\$a\_n-a\_{n-1}\$). Then `vabs` gets the absolute values of that. `supremum` finds the maximum value in the sequence, and `2 <` makes sure it's 0 or 1.
[Answer]
# [Python 3](https://docs.python.org/3/), 45 bytes
```
lambda k:all(-2<x-y<2for x,y in zip(k,k[1:]))
```
**[Try it online!](https://tio.run/##K6gsycjPM/6fZhvzPycxNyklUSHbKjEnR0PXyKZCt9LGKC2/SKFCp1IhM0@hKrNAI1snO9rQKlZT839BUWZeiUaaRrShjoKRjoKxjoIJjDSFIROQQgA "Python 3 – Try It Online")** or **[Try the test suite.](https://tio.run/##XZDBDoMgDIbvPEWPmtREQOc0@iSOg8tiRmRqjAfdyztgoHPJXyj/B7TpuM7PoedbW9021bzujwa6olEqiFi5RGvJ2mGCBVeQPbzlGHTY1bQQYbgpqKCuKQJD4AiJX1OvRCA5ce1dEDKEK0KuV8O5hSc5O/HaiXPO35pT6u8xx7gtltkymc21Qx386q8rmh9lf/s0r4@CGtJYx9XtcWyZTpkOvocQhJjBSTM2VRAYJ9nPQRtIPbgP)**
Thanks to [Jonathan Frech](https://codegolf.stackexchange.com/users/73111/jonathan-frech) for -2 bytes.
[Answer]
# [MATL](https://github.com/lmendo/MATL), ~~6~~ 5 bytes
```
d|2<A
```
-1 byte thanks to *Giuseppe*
[Try it online!](https://tio.run/##y00syfn/P6XGyMbx//9oQx0FIx0FYx0FExhpCkMmsQA "MATL – Try It Online") or [Verify all test-cases](https://tio.run/##y00syfmf8D@lxsjG8b9LyP9oQx0FIx0FYx0FExhpCkMmsVwo0kAhMx0Fcx0FCx0FSyAJlDYGy6EgiKgJDMEloCIoZgI5pjBVRhAZY7A95mAbzMFsoIghRA6C0NxjaAm3EdmBIL1wu4ByhgZAbAGlDQxAUkCWERAbw3GsgoICAA "MATL – Try It Online")
[Answer]
# [anyfix](https://github.com/alexander-liao/anyfix), 9 bytes
```
I€A€2<»/&
```
[Try it online!](https://tio.run/##S8yrTMus@P/f81HTGkcgNrI5tFtf7f///9GGOgpGOgrGOgomMNIUhkxiAQ "anyfix – Try It Online")
```
I€A€2<»/&  Main Link
I          Deltas
 €         For each element
  A        Take its absolute value
   €  »    For each element
    2<     Is it less than two?
       /   Reduce over
        &  Logical AND
```
This is mostly a port of the 05AB1E solution except terrible because anyfix doesn't have autovectorization and other cool things
[Answer]
# [Java (OpenJDK 8)](http://openjdk.java.net/), 60 bytes
```
a->{int r=1,p=a[0];for(int i:a)r|=(r=p-(p=i))*r;return r<2;}
```
[Try it online!](https://tio.run/##jVJtb4IwEP7ur7iYmMBSkBfZVMRkP2DJkn00fqgIpg4LaYuJcfx2VlogKmYZubvS63PPXZvniM/YyouEHvffdVHuMhJDnGHO4QMTCtcRQJvlAgu5nHOyh5M8M74EI/Sw2QJmB242SICjpLNLQTI7LWksSE7tT5bsSYxFsiJUbLZrSCGCGlvrq9wDi1xURHjjbMM0Z0aTIktssp/IYFFhGUVETPOFhSwRJaPAVl5Y1aHqpehke5FwwSWnngDg6iLwEPgIZl0MOptVCKZTEKxMnqEl4hXBG4I5goWMQ7SvoHcmQf03RM866wvazF@T3FI@ckMHDzpa719wV2EDdb2FioHKuLpawlOc8dthtD08jrtQ@Ef48P2aBv1gT9g9VeE60uft6jhtwQAuTz3pfu93V76DV1odUk1gKIkogSy1TMxeJV8XLpKTnZfCLqSORWqMJ5bv8SVMdhM6RjdSfmcMX7gtcq14o2EyEaR286N3pm5ajRqv6l8 "Java (OpenJDK 8) – Try It Online")
* 5 bytes thanks to @Nevay!
[Answer]
# C, ~~61~~ 56 bytes
*Thanks to @scottinet for saving five bytes!*
```
r;f(a,n)int*a;{for(r=1;--n;r=(*a-*++a)/2?0:r);return r;}
```
[Try it online!](https://tio.run/##fdPNboQgEADgu08x2aQJuJgC/peYPkjbg7Frs4fShtqT8dkt4GJ1MRhQA87nOGCXfHTdPCvRo5ZIfJVD3Iqx/1JINUwkiRSqQXGbxOdzix/5M31SWKjL8KskKDHNOgA@26tEOBoj0IcZGC4/A3t5gwZGRoATSAlk7py7lk3CRnwrHdOj08P7qzwR6JENJ8AoxiLaodxHNVQQKAlUBGp9DqH8EE0XNLXiroUsPV96VLZSmWurdhsJmdlhfvn9R4cIU1dPKBYhdwnxA2FjFM7YIeWaRmqrXtp6l/Zej7BQVuZZL6tqBZd2t6SsDonVkVhvy7/dGCbLkGY2jqcxui28XRvdq9uV0uD2pUfbg7mfQs9y3dO1e9a/pF@fG2ma/wA)
# C (gcc), 47 bytes
```
r;f(a,n)int*a;{for(r=1;--n;r=(*a-*++a)/2?0:r);}
```
[Try it online!](https://tio.run/##fdPNboQgEADgu08x2aQJ7GIK@F9i@iBtD8bWZg@1DfVmfHY74GJ1MRhAw8/nOGAbf7btPGvVkYb19NoP50aN3bcmuhYqjnula3Ju4vPl0tBH@cyfNFXTjPPgq7n2hEZjBHiZjuHjdxAvb1DDKBhIBgmD1LWZK@mk7IofjWs6cnp4f@1PDDpilzMQnFIV7VDpowjlDAoGJYMK2xAqD9FkQRMr7krIwvHCo9KVSl1ZtVtPyEwP48vuPzpEmLx6Qr4ImQtIHggbI3fGDinWMBKb9cLmu7DP2CNCUZm5XlTlCi7lbktFFRLLI7Hapn97MEyUIc0cHE8TfJt4uzdYy9ud8@Dx5UfHQ7ifAkcl1mStnvUv4eszI03zHw)
[Answer]
# [Ruby](https://www.ruby-lang.org/), 36 35 33 bytes
```
->b,*a{a.all?{|x|(b-(b=x))**2<2}}
```
Takes the input array as individual arguments.
-1 byte thanks to MegaTom, -2 bytes thanks to Jordan.
[Try it online!](https://tio.run/##KypNqvyfZvtf1y5JRyuxOlEvMSfHvrqmokYjSVcjybZCU1NLy8jGqLb2f0FpSbFCWrShjoKRjoKxjoIJjDSFIZNYLiyKgBJmOgrmOgoWOgqWQBKuyBisAgUhy5nAEFwaKoLFFriQKUyHEbIqY7ArzMH2m4PZQBFDZBUQhOZmQ0s09yB7BWQOmkuAKgwNgNgCShsYIBQA@UZAbAzHsf8B "Ruby – Try It Online")
[Answer]
# [Julia 0.6](http://julialang.org/), 21 bytes
```
~x=all(diff(x).^2.<2)
```
[Try it online!](https://tio.run/##fZFha8MgEIa/51cc/aQgJZqka8YcDPYvwg3CkhQXyUq00H3pX8@sM1lcy@S9E86H9zz9OGlV76bpcpa11qRRXUfOdPsmtk@CTo18Ve@WJBVnIBhkDPI5F7NyBPkMdjy1LObc2Y7BA4M9g9LlNZd5KBLCsiIun7WgoXK/78rmjl8xO4n/Oe6hwl@/9LnwFY6B62ptAvijP2PzEmPw9k2upvjbeeUoPMtTF/uwpynegK4uXGRLYDxLAGmSHEc1WD2QzYvWYFtjDRxrY9RweIQNg@vPV5cepISm6hG6zxF6UAP07ZchDUVKp28 "Julia 0.6 – Try It Online")
-1 byte thanks to MarcMush: pass a single argument to `all`
[Answer]
# [Java (OpenJDK 8)](http://openjdk.java.net/), 78 bytes
```
a->{int p=0,i=1;for(;i<a.length;p+=Math.abs(a[i]-a[i++-1])>1?1:0);return p<1;}
```
[Try it online!](https://tio.run/##Lc7NboMwEATgV9kjFGPF/ZNaA5Fy6K2nnCrEYUtMYgpryyypIsSzU6utNJrDN5fp8Yq584b609dmR@8CQx9NzmwH2c3UsnUk77QlNqHD1sDH8vbPRcS6EXBwbjBIFQQoYcO8WuIAvtwJWyrduZBoW6AcDJ35on1WviNfJH5OCda2yWNlWa6atFJ79bpLdTA8BwJfKL1uemJk28LV2ROMaCk5crB0rhtMl@NtYjNKN7P0EXmgJEj0frglZL7h99@iBPzlXsCDgEcBTwKeo7ysaarXdfsB "Java (OpenJDK 8) – Try It Online")
[Answer]
## JavaScript (ES6), ~~37~~ 36 bytes
```
(a,u)=>!a.some(e=>(e-=(u=e))>1|e<-1)
```
Edit: Saved 1 byte by stealing @Arnauld's trick.
[Answer]
# Pyth, 7 bytes
```
._I#I.+
```
[Test Suite](http://pyth.herokuapp.com/?code=._I%23I.%2B&test_suite=1&test_suite_input=%5B1%2C+2%2C+3%2C+4%2C+3%2C+4%2C+5%2C+5%2C+5%2C+4%5D%0A%5B1%2C+2%2C+3%2C+4%2C+5%2C+6%2C+7%2C+8%2C+9%2C+8%5D%0A%5B3%2C+3%2C+3%2C+3%2C+3%2C+3%2C+3%5D%0A%5B3%2C+4%2C+4%2C+4%2C+3%2C+3%2C+3%2C+4%2C+4%2C+4%5D%0A%5B1%2C+2%2C+3%2C+4%5D%0A%5B5%2C+4%2C+3%2C+2%5D%0A%5B1%2C+3%2C+5%2C+7%2C+9%2C+7%2C+5%2C+3%2C+1%5D%0A%5B1%2C+1%2C+1%2C+2%2C+3%2C+4%2C+5%2C+6%2C+19%5D%0A%5B3%2C+4%2C+5%2C+6%2C+7%2C+8%2C+7%2C+5%5D%0A%5B1%2C+2%2C+4%2C+10%2C+18%2C+10%2C+100%5D%0A%5B10%2C+20%2C+30%2C+30%2C+30%5D&debug=0)
Returns true/false.
Explanation:
```
     .+ Deltas, returns differences between consecutive values.
._      Signum, returns the sign of a number (1, 0, or -1).  Note that this should
             be equal to the input for insignificant arrays.
  I     Tests if it is equal to the input...
   #    For each in the input, and filter out those that aren't...
    I   And make sure none have been filtered out.
```
[Answer]
## Mathematica, 34 bytes
```
Differences@#~MatchQ~{(1|0|-1)..}&
```
# Explanation
```
                                 & (* Function *)
Differences                        (* which takes the consecutive differences*)
           @#                      (* of the input list *)
             ~MatchQ~              (* and returns whether it matches *)
                     {(1|0|-1)..}  (* a list consisting of one or more 1s, 0s, or -1s *)
```
]