Added solution for GoodNodes Problem