Nothing exists. Everything is a creation of thought. The sun is just energy which is given is shape in physical reality by the brain. the most awesome quantum computer ever created. So its not that sun isnt there when you are not viewing it, it that the sun isnt there ever.
Try reading Crack in the cosmic egg by Joseph Pearce. Its a hard read but well worth the effort.