Finished work for Coursera Algorithms course