!expr is the logical NOT function. It gives False if expr is True, and True if it is False.
Not[expr] can be input in most cases as expr. The character can be entered as !, not or \[Not].
Not gives symbolic results when necessary, applying various simplification rules to them. If you are using Mathematica TE with a text-based front end, then you cannot use the notation !expr for Not[expr] if it appears at the very beginning of a line. In this case, !expr is interpreted as a shell escape. See The Mathematica Book on the web: Section 1.5.6. See also: LogicalExpand, BitNot, Nor.