//
// Written by Fyodor Menshikov 06.03.2010
// 13:44-13:59
//

import java.io.*;
import java.util.*;

class Assert {
   static void check(boolean e) {
      if (!e) {
         throw new Error();
      }
   }
}

public class Main {

   Scanner in;
   PrintWriter out;

   int getSum(int n) {
      int sum = 0;
      while (n > 0) {
         sum += n % 10;
         n /= 10;
      }
      return sum;
   }

   void number(int value, int nDigits) {
      Assert.check(value >= 0);
      Assert.check(nDigits > 0);
      if (nDigits == 1) {
         Assert.check(value <= 9);
      } else {
         number(value / 10, nDigits - 1);
      }
      out.print(value % 10);
   }

   void part(int nDigits, int sum) {
      int count = 1;
      for (int i = 0; i < nDigits; i++) {
         count *= 10;
      }
      boolean first = true;
      for (int i = 0; i < count; i++) {
         if (getSum(i) == sum) {
            if (first) {
               first = false;
            } else {
               out.print("|");
            }
            number(i, nDigits);
         }
      }
   }

   void solve() {
      int nDigits = in.nextInt();
      Assert.check(nDigits % 2 == 0 && 2 <= nDigits && nDigits <= 6);
      Assert.check(nDigits == 2 || nDigits == 4 || nDigits == 6);
      boolean first = true;
      for (int sum = 0; sum <= nDigits / 2 * 9; sum++) {
         if (first) {
            first = false;
         } else {
            out.print("|");
         }
         out.print("(");
         part(nDigits / 2, sum);
         out.print(")(");
         part(nDigits / 2, sum);
         out.print(")");
      }
      out.println();
   }

   void run() {
      try {
         in = new Scanner(System.in);
         out = new PrintWriter(System.out);
      } catch (Exception e) {
         throw new Error(e);
      }
      try {
         solve();
      } finally {
         out.close();
      }
   }

   public static void main(String args[]) {
      new Main().run();
   }
}
