finished pseudocode for first array method
finished initial solution for first pad method