Revelation 20:12-15 AMPC
I [also] saw the dead, great and small; they stood before the throne, and books were opened. Then another book was opened, which is [the Book] of Life. And the dead were judged (sentenced) by what they had done [their whole way of feeling and acting, their aims and endeavors] in accordance with what was recorded in the books.
And the sea delivered up the dead who were in it, death and Hades (the state of death or disembodied existence) surrendered the dead in them, and all were tried and their cases determined by what they had done [according to their motives, aims, and works].
Then death and Hades (the state of death or disembodied existence) were thrown into the lake of fire. This is the second death, the lake of fire.
And if anyone's [name] was not found recorded in the Book of Life, he was hurled into the lake of fire.
AMPC: Amplified Bible, Classic Edition