by a nose; photo finish
Used in horse racing and metaphorically for a very narrow margin of victory or difference.
See also: 鼻差
He won the race by a nose.
選挙はまさに鼻の差だった。
The election was a real photo finish.
Literally 'difference of a nose', from the horse racing term for a win by a nose.