solve friendly-number