In the case of my mother, who was in her 80's, yes. She was confused during several hospitalizations, but returned to her rational self after returning home.
My MIL, however, was having significant memory loss and signs of dementia when she entered the hospital, and being there only exacerbated her issues. She was completely confused and hostile to staff members during several hospitalizations. She would get back to her own level of "normal" when she returned home, but each time she went in the hospital, the hostility, etc. happened again.