Solution to problem id subs