OH yes sir(and/or/maybe mam), it is completely doable. Since the dawn of the programmer, we have been portrayed as fairly portly dweebs who exist in a chronic sitting position. While this has been true in the past, and surely is at the moment (who the fuck would even purchase a diabetic calendar - tres bizarre), we can do a lot to help ourselves stay healthy while still doing what we absolutely love.
Change is hard(it really is sad about Lenovo moving to chicklet stylz), especially when it comes to the food we shove in our pie-holes. However, programmers are accustom to change. They pivot constantly, change their working environments and generally don't have a problem with this...right? Keeping this easy then, let's just stop eating carbohydates and sugar. Pretty easy huh?
No carbs and no sugars means no spaghetti, pasta, bread, muffins, cakes, any of it. To make this transition easy, follow this rule six out of seven days in the week (one day off). Ok, so why right? Well sugar and carbs force your pancreas to produce a lot of insulin which will inevitably lead to diabetes and weight gain. Both of these things, if you are lost, are bad.
And that's it? Yep! Well...actually, give a standing desk a whirl. They can be hard to get used to; however, are great for your posture, back strength, legs, etc in the long run. If you are worried about standing all day (it is hard at first) find one that auto-magically moves up and down. They are expensive but will add years onto the backend of your life in order for you to continue to do what you love well into your old age. Go forth and be a healthy, kick-ass programmer!