for i in range(100,1000): m=i//100 n=(i-m*100)//10 o=i-m*100-n*10 if i==m**2+n**2+o**2: print(i)
Standard input is empty
Standard output is empty
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!