def lfu_for_evict(cache_dict, evict_number=<NUM_LIT:1>):
ordered_dict = sorted(cache_dict.items(), key=lambda t: t[<NUM_LIT:1>]['<STR_LIT>'])<EOL>evicted_keys = []<EOL>if len(cache_dict) < evict_number:<EOL><INDENT>evict_number = len(cache_dict)<EOL><DEDENT>for i in range(evict_number):<EOL><INDENT>item = ordered_dict[i]<EOL>key = item[<NUM_LIT:0>]<EOL>cache_dict.pop(key)<EOL>evicted_keys.append(key)<EOL><DEDENT>return evicted_keys<EOL>
Use LFU(Least Frequently Used) strategy for evicting, the item that number of hits is the least will be removed.

Test:
>>> from common_cache import CacheItem
>>> dict = {}
>>> dict['a'] = CacheItem(key='a', value=0, expire=5)
>>> dict['b'] = CacheItem(key='b', value=1, expire=5)
>>> dict['c'] = CacheItem(key='c', value=2, expire=5)
>>> len(dict)
3
>>> dict['a'].update_hit_count()
>>> dict['a'].update_hit_count()
>>> dict['a'].update_hit_count()
>>> dict['b'].update_hit_count()
>>> lfu_for_evict(dict)
['c']
>>> lfu_for_evict(dict)
['b']
>>> lfu_for_evict(dict)
['a']
>>> len(dict)
0