Shortened code

Shortened the code for the lifestyle calculation