Would Your Photos Delete If You Sign Out Of Your ICloud Acc?

Okay so I'm scared to log out of my ICloud acc. When I press sign out it says if I sign out all of my pictures will be removed from my iPad. I have very important pictures and I'm afraid of loosing them. All I'm wondering is: if I log out of my iCloud acc then sign into a new one then later on sign back to my old one would all my pictures be in my gallery?

Original thread: https://forums.imore.com/threads/would-your-photos-delete-if-you-sign-out-of-your-icloud-acc.383679/