Write down the corresponding memory consumption in bytes 

Hi, I have a question and I hope anyone could answer it:

Write down the corresponding memory consumption in bytes 

1. int age[10] = ………

2. charname[10] = ……….

3. int age[10][10]= ………..

1 Answer

  1. Answer:

    1. 4*10 = 40 bytes (4 bytes for one integer)
    2. 1*10=10 (one byte for each character)
    3. 4*10*10 = 400 (4 * 100 elements)

You must login to add an answer.

Related Questions