For Windows 11 users, the latest Notepad.exe can also pick up where you left off the last time the app was closed.
I just tried this, opened a bunch of tabs and edited the text in them all.
Right click tabs, close all to the right, left or close all but this.
Then it shows a message box asking to save, click No To All.
All tabs closed :)