Yeah, I used to watch that show all the time. Once they had this guy on who swallowed a mixed-up Rubic's Cube. Then he twisted his stomach around for a while with his hands, before coughing up a fully-solved cube.
There are two ways I can think of that he may have performed the trick:
1) He never actually swallowed anything, but did some sleight-of-hand that made it look like he was swallowing/regurgitating stuff. He had a solved cube hidden the whole time.
2) He swallowed a solved cube before the show, and somehow coughed that one up instead of the mixed-up one.