Two steps inside the fence, he felt an unpleasant electric shock. Albus took the electric shock to be a warning ward; if he continued to walk forwards, he would run into a fatal ward before he touched the brick wall.