Google interview question

Develop an algorithm to sort 100m books and find functional duplicates