refactored
code refactored w/o data and logic seperation
code refactoring with underscore.js