a="$System.in".split('\n')*.tokenize(': ');while(a){a.remove o=a.find{it.size<2};println v=o[0];a.each{it.remove v}}