How can the techniques of computer science help us in everyday life? We speak to Brian Christian co-author of ‘Algorithms to Live by: The Computer Science of Human Decisions’. He argues that the techniques of computer science can help us manage everyday situations in a more logical and efficient manner. So which algorithm can help solve the problem of odd socks? And what is the most efficient way of alphabetising your book collection? Tim Harford investigates.