How does
mem /U /NOSUMMARY
know which program is in which location?
Where is this information and its program name stored?
And how does a program know in DOS, which memory area is free and which it can use without overwriting an existing program or data?