Trolly versions of classic algorithms