sample for observer pattern
merged