part 1 & 2
part 3 - sorting