Amazon has many visitors to its site. And it tracks what pages the customers visited, etc and other stuff.
Make an efficient data structure for storing 3 days of information of all those customers who have visited site exactly two different days and searched more than 3 unique pages of the site in those 2 days.
So whoever visited site exactly two days out of these three days and visited more then 3 unique pages should be in the contact list.
What’s the efficient approach to solve these kinds of problems?