Only two algorithms are used in this case. After solving it, keep practicing! Make sure to check the Tips page out.