Since ^ has the same interpretation by grep(BRE) and egrep(ERE) it works the same in both. It uses Basic Regular Expression which means if you use grep 'ab' it will not not use this '' as OR operator without using this '\' prefix.
If you run it with a plain grep command you will get nothing, because grep doesn't know such thing as | command. pgrep is not Perl grep, it’s process grep (from the same package as pkill) 2. It will grab to output from ls all names which contain either "mp4" or "avi" strings. 4.The egrep command allows the use of extended regular expressions while grep only searches for the matching word or term that the user specified in the command. In this example | acts like an OR command. So, for example, you want to list files in a directory and see only those which contain "mp4" or "avi" as filename extensions. Thus, with egrep, the character | means logical OR. These aren't ordinary characters like we may use in words or filenames but are control commands for the grep binary itself. This allows use of meta-symbols such as +, ? or |.
The difference is that -E option enables usage of extended regexp patterns. The egrep command is a shortcut for the grep binary, but with one exception: when grep is invoked as egrep, the grep binary activates its internal logic to run as if it were called as grep -E.