Adding code of coin sum equal to S problem