lists:filter(fun({A,B,C}) -> (A*10+B)*A == C*100+C*10+C end,[{A,B,C}||A<-lists:seq(0,9),B<-lists:seq(0,9),C<-lists:seq(0,9)]