I never remember whether ^
matches the beginning of the line and $
matches the end of it or the other way around. A good mnemonic would be that the $
sign is always before the price, therefore it matches the beginning of a line - unfortunately it's the other way around.
So is there any reason why these two characters were chosen for the beginning and end of line?