Skip to main content
Commonmark migration
Source Link

#MATLAB / Octave, 38 bytes

MATLAB / Octave, 38 bytes

@(x)any(all([x;flip(x)]'==sort(x)',1)) 

Online demo

#MATLAB / Octave, 38 bytes

@(x)any(all([x;flip(x)]'==sort(x)',1)) 

Online demo

MATLAB / Octave, 38 bytes

@(x)any(all([x;flip(x)]'==sort(x)',1)) 

Online demo

added 43 characters in body
Source Link
Suever
  • 11.2k
  • 1
  • 24
  • 52

#MATLAB / Octave, 38 bytes

@(x)any(all([x;flip(x)]'==sort(x)',1)) 

Online demo

#MATLAB / Octave, 38 bytes

@(x)any(all([x;flip(x)]'==sort(x)',1)) 

#MATLAB / Octave, 38 bytes

@(x)any(all([x;flip(x)]'==sort(x)',1)) 

Online demo

Source Link
Suever
  • 11.2k
  • 1
  • 24
  • 52

#MATLAB / Octave, 38 bytes

@(x)any(all([x;flip(x)]'==sort(x)',1))