Updated pseudocode

Fixed misspelling and elaborated on pseudocode