import java.util.*;
public class Main{
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        while(sc.hasNext()){
            int n=sc.nextInt();
            for(int i=0;i<=14;i++){
                if((100-7*i)%4==0){ 
                    System.out.print(i+" ");
                    int x=(100-7*i)/4;
                    System.out.print(x+" ");
                    System.out.print(100-i-x+" ");
                    System.out.println("");
                }
            }
        }
    }
}