This is an example problem in a computer organization and architecture course that's giving me some trouble. It goes as follows:Consider a cache of 4 lines of 16 bytes each. Main memory is divided  into blocks of 16 bytes each. That is, block 0 has bytes with  addresses 0 through 15, and so on. Now consider a program that  accesses memory in the following sequence of addresses:Once: 63-70Loop 10 times: 15-32; 80-95a. Suppose the cache is organized as direct mapped. Memory blocks 0,  4, and so on are assigned to line 1; blocks 1, 5, and so on to line 2;  and so on. Compute the hit ratio.b. Suppose the cache is organized as two-way set associative, with two  sets of two lines each. Even-numbered blocks are assigned to set 0 and  odd-numbered blocks are assigned to set 1. Compute the hit ratio using  the least recently used replacement scheme.I know that the formula for finding the hit ratio is:hit ratio = hits / (hits + misses)and that the LRU replacement scheme should be used for both a and b, since it's the most efficient. I know how to find and compute addresses in a cache, but this has me stumped.Any help in understanding this is greatly appreciated!
Computing the hit and miss ratio of a cache organized as either direct mapped or two-way associative
computer architecture;cpu cache