Two dimensional 512 byte (byte addressable) RAM from 16 byte chips
We have 512B of memory RAM and the size of each chip is 16B. Therefore, we need 512B/16B = 32 chips. Memory address register needs to address 16B = 2^4B. Thus, we need 4 bits to address single chip. The 9bits needed in total minus the already used 4 bits (512B=2^9, 16B=2^4) and we are left with 5bits for decoding. We are ask to design a two dimensional RAM with decoders of size 3 to 8 and/or 2 to 4. So, we use 2bits for decoder 2 to 4 and the left 3 bits for the 3 to 8 decoder. We get a two dimensional RAM 4X8 which is equal 32.