Second that emotion on the exercise. And diet is equally important. While the Red Bull, pizza, and caffeine swilling stereotype is prevalent, a well-thought out and balanced diet can make your coding more productive. You'll be creating fewer bugs, thinking more clearly, and feeling more positive about your progress if your (exercised) body has the fuel it needs, too. And reducing the number of stimulants you're ingesting will help with that whole sleeping thing too.