updated 2 working functions, but last number is not picked up