That's on you. You should try writing them down. Depends on what your password is for. If it's for your Apple or Google account, they can factory reset your phone but if it's for your pin code, they can take care of that too. Contact them directly.
Unfortunately it would erase everything with a reset.
I know it was my fault but would it erase everything I had in there if they fixed it?
Thanks! Your answer is awaiting moderation.