read this http://latentflip.com/imperative-vs-declarative/