Wasn't the game tied when NC State took possession? The idea would be to run down the clock to the last few seconds and take away Houston's opportunity to win the game on their final possession. Hurling the ball from 30 feet probably wasn't the way the coach drew it up, but a bad shot with no time left is better than a good shot with 5 or 10 seconds left.
The plan was always for Whittenburg to take the last shot, since it was a tie game and V didn't want to give the ball back to Houston in regulation. The pass to him was almost stolen away, though, and by the time he got the ball back under control, there wasn't enough time for him to do anything but throw up the prayer from where he was standing. The luckiest thing about that play from NC State's perspective was that Akeem had his back to the basket ready to pull down the rebound, never saw it fall short, and so never even contested Lorenzo Charles' dunk.