The whole memory of 1MB is devided into 4 segments which are addressable using separate registers:
CS = Code Segment
DS = Data Segment
SS = Stack Segment
ES = Extra Segment
These 16-bit registers are used to create 20-bit address which is used to access Code, Data , Stack ...
There is no way you will address two different memories at the same time ..
its same as mapping in case of microprocessor 8085 only difference is that there are 20 bits address lines.......and 16 data lines.........
you have to find the starting address and final address according to questions and size of ram or rom asked
then u can use decoder if u have more than 2 or three memory elements otherwise u can do in general way using And and Not gates .......
in the case of rom there will be no write line others are all same as that of ram.