Implementing both direct-mapped and Set-associative caches using the same code
An input file named "input.txt" should contain the series of memory accesses, which will be simulated using this cache and the number of cache-hits, cache-misses and writebacks to the memory locations are given as the output in a file named "output".