A bit of pythonic approach.