There was a man he lives in a hotel each morning he presses the first floor button each evening if there is a person in the elevator he asks him to press the 10 floor button if there is no one in the elevator he takes the stairs why.
You are provided with a grid (as shown in the picture). Can you fill the squares with numbers 1-8 in a manner that none of the two consecutive numbers are placed next to each other in any direction (vertically, horizontally or diagonally?)