figuring out logic for withdrawal process