There are a lot of algorithm realizations as exercises.