How can a pawn move or attack in chess? If you asked a random person on the street this question, 3 times out of 10 they'll ignore you until you pester them further.
Most people know that a pawn can only move forwards. If it's the pawn's first move, it can either move one or two spaces forward, otherwise only one.
Whilst attacking a pawn can only move and attack one space diagonally forwards (up right or up left).
Except that's not exactly the truth since it can sometimes attack to the left or right of itself. Very few casual players know of this mechanic, but that's understandable since it is a special move that can only be performed under very specific circumstances.
This move is known as "En Passant" which is French for in passing.
If the opponent moves a pawn two spaces (on the first move) and it ends up next to one of your pawns you can perform an En Passant. A capture in passing. You would be attacking the space the other pawn would have been at if it only moved one space forward. Your pawn will thus move diagonally and capture the pawn that was to the left or right of itself.
This move only works directly after the opponent's pawn was first moved.
This only happens very rarely because you'd first need to get your pawn onto the opponents half of the board and then for the opponent to attempt to avoid the pawn.
This is a move that beginners will most likely oversee, due to never having heard of it before.