Obviously, they execute in slightly different context - the inline script is "top-level" code, the DOMContentLoaded handler is in an event listener function.
Perhaps also obviously, DOMContentLoaded is executed some time after the last inline script. See HTML5 specification for the list of steps supposed to happen in between.
DOMContentLoaded is useful in cases when you don't control the markup, e.g. library code or something like browser extensions (See also Unobtrusive JavaScript)