Write a program or function that takes in a positive integer. You can assume the input is valid and may take it as a string. If the number is any of
123
234
345
456
567
678
789
then output a truthy value. Otherwise, output a falsy value. For example, the inputs
1
2
3
12
122
124
132
321
457
777
890
900
1011
1230
1234
must all result in falsy output. (The input will not have leading zeroes so you needn't worry about things like 012
.)
The shortest code in bytes wins.
012
? \$\endgroup\$012
would be falsy but you can assume it is not input. \$\endgroup\$