Wouldn’t it depend on how the world ended? Quite a few celestial events wouldn’t give any life on Earth a moment to even register that the world ended. Others, say, like an asteroid, it’s possible that some would have enough time to register that it is indeed the end.
And if, say, the sun suddenly just disappeared, we’d know as the world grows colder and colder in perpetual night, flying off in a tangent from whatever position Earth was at in its orbit 8 minutes after the sun vanished.