import java.util.Scanner; public class Main{ public static void main(String[] args) { Scanner sc=new Scanner(System.in); int n=sc.nextInt();//2 sc.close(); for (int i = 0;i<=Math.sqrt(n/4) ;i++) { for (int j = i; j<=Math.sqrt((n-i*i)/3); j++) { for (int k = j; ; k++) { int m=n-i*i-j*j-k*k; double num=Math.sqrt(m); if(num<k)break; if(num%1==0) { System.out.printf("%d %d %d %d\n",i,j,k,(int)num); return; } } } } } }
0.0分
1 人评分