QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#104532#6395. Equation DiscoveringmaspyAC ✓169ms150452kbC++2015.4kb2023-05-10 23:05:062023-05-10 23:05:08

Judging History

你现在查看的是最新测评结果

  • [2023-08-10 23:21:45]
  • System Update: QOJ starts to keep a history of the judgings of all the submissions.
  • [2023-05-10 23:05:08]
  • 评测
  • 测评结果:AC
  • 用时:169ms
  • 内存:150452kb
  • [2023-05-10 23:05:06]
  • 提交

answer

#line 1 "library/my_template.hpp"
#if defined(LOCAL)
#include <my_template_compiled.hpp>
#else
#pragma GCC optimize("Ofast")
#pragma GCC optimize("unroll-loops")

#include <bits/stdc++.h>

using namespace std;

using ll = long long;
using u32 = unsigned int;
using u64 = unsigned long long;
using i128 = __int128;

template <class T>
constexpr T infty = 0;
template <>
constexpr int infty<int> = 1'000'000'000;
template <>
constexpr ll infty<ll> = ll(infty<int>) * infty<int> * 2;
template <>
constexpr u32 infty<u32> = infty<int>;
template <>
constexpr u64 infty<u64> = infty<ll>;
template <>
constexpr i128 infty<i128> = i128(infty<ll>) * infty<ll>;
template <>
constexpr double infty<double> = infty<ll>;
template <>
constexpr long double infty<long double> = infty<ll>;

using pi = pair<ll, ll>;
using vi = vector<ll>;
template <class T>
using vc = vector<T>;
template <class T>
using vvc = vector<vc<T>>;
template <class T>
using vvvc = vector<vvc<T>>;
template <class T>
using vvvvc = vector<vvvc<T>>;
template <class T>
using vvvvvc = vector<vvvvc<T>>;
template <class T>
using pq = priority_queue<T>;
template <class T>
using pqg = priority_queue<T, vector<T>, greater<T>>;

#define vv(type, name, h, ...) \
  vector<vector<type>> name(h, vector<type>(__VA_ARGS__))
#define vvv(type, name, h, w, ...)   \
  vector<vector<vector<type>>> name( \
      h, vector<vector<type>>(w, vector<type>(__VA_ARGS__)))
#define vvvv(type, name, a, b, c, ...)       \
  vector<vector<vector<vector<type>>>> name( \
      a, vector<vector<vector<type>>>(       \
             b, vector<vector<type>>(c, vector<type>(__VA_ARGS__))))

// https://trap.jp/post/1224/
#define FOR1(a) for (ll _ = 0; _ < ll(a); ++_)
#define FOR2(i, a) for (ll i = 0; i < ll(a); ++i)
#define FOR3(i, a, b) for (ll i = a; i < ll(b); ++i)
#define FOR4(i, a, b, c) for (ll i = a; i < ll(b); i += (c))
#define FOR1_R(a) for (ll i = (a)-1; i >= ll(0); --i)
#define FOR2_R(i, a) for (ll i = (a)-1; i >= ll(0); --i)
#define FOR3_R(i, a, b) for (ll i = (b)-1; i >= ll(a); --i)
#define overload4(a, b, c, d, e, ...) e
#define overload3(a, b, c, d, ...) d
#define FOR(...) overload4(__VA_ARGS__, FOR4, FOR3, FOR2, FOR1)(__VA_ARGS__)
#define FOR_R(...) overload3(__VA_ARGS__, FOR3_R, FOR2_R, FOR1_R)(__VA_ARGS__)

#define FOR_subset(t, s) \
  for (ll t = (s); t >= 0; t = (t == 0 ? -1 : (t - 1) & (s)))
#define all(x) x.begin(), x.end()
#define len(x) ll(x.size())
#define elif else if

#define eb emplace_back
#define mp make_pair
#define mt make_tuple
#define fi first
#define se second

#define stoi stoll

int popcnt(int x) { return __builtin_popcount(x); }
int popcnt(u32 x) { return __builtin_popcount(x); }
int popcnt(ll x) { return __builtin_popcountll(x); }
int popcnt(u64 x) { return __builtin_popcountll(x); }
// (0, 1, 2, 3, 4) -> (-1, 0, 1, 1, 2)
int topbit(int x) { return (x == 0 ? -1 : 31 - __builtin_clz(x)); }
int topbit(u32 x) { return (x == 0 ? -1 : 31 - __builtin_clz(x)); }
int topbit(ll x) { return (x == 0 ? -1 : 63 - __builtin_clzll(x)); }
int topbit(u64 x) { return (x == 0 ? -1 : 63 - __builtin_clzll(x)); }
// (0, 1, 2, 3, 4) -> (-1, 0, 1, 0, 2)
int lowbit(int x) { return (x == 0 ? -1 : __builtin_ctz(x)); }
int lowbit(u32 x) { return (x == 0 ? -1 : __builtin_ctz(x)); }
int lowbit(ll x) { return (x == 0 ? -1 : __builtin_ctzll(x)); }
int lowbit(u64 x) { return (x == 0 ? -1 : __builtin_ctzll(x)); }

template <typename T, typename U>
T ceil(T x, U y) {
  return (x > 0 ? (x + y - 1) / y : x / y);
}
template <typename T, typename U>
T floor(T x, U y) {
  return (x > 0 ? x / y : (x - y + 1) / y);
}
template <typename T, typename U>
pair<T, T> divmod(T x, U y) {
  T q = floor(x, y);
  return {q, x - q * y};
}

template <typename T, typename U>
T SUM(const vector<U> &A) {
  T sum = 0;
  for (auto &&a: A) sum += a;
  return sum;
}

#define MIN(v) *min_element(all(v))
#define MAX(v) *max_element(all(v))
#define LB(c, x) distance((c).begin(), lower_bound(all(c), (x)))
#define UB(c, x) distance((c).begin(), upper_bound(all(c), (x)))
#define UNIQUE(x) \
  sort(all(x)), x.erase(unique(all(x)), x.end()), x.shrink_to_fit()

template <typename T>
T POP(deque<T> &que) {
  T a = que.front();
  que.pop_front();
  return a;
}
template <typename T>
T POP(pq<T> &que) {
  T a = que.top();
  que.pop();
  return a;
}
template <typename T>
T POP(pqg<T> &que) {
  assert(!que.empty());
  T a = que.top();
  que.pop();
  return a;
}
template <typename T>
T POP(vc<T> &que) {
  assert(!que.empty());
  T a = que.back();
  que.pop_back();
  return a;
}

template <typename F>
ll binary_search(F check, ll ok, ll ng, bool check_ok = true) {
  if (check_ok) assert(check(ok));
  while (abs(ok - ng) > 1) {
    auto x = (ng + ok) / 2;
    tie(ok, ng) = (check(x) ? mp(x, ng) : mp(ok, x));
  }
  return ok;
}
template <typename F>
double binary_search_real(F check, double ok, double ng, int iter = 100) {
  FOR(iter) {
    double x = (ok + ng) / 2;
    tie(ok, ng) = (check(x) ? mp(x, ng) : mp(ok, x));
  }
  return (ok + ng) / 2;
}

template <class T, class S>
inline bool chmax(T &a, const S &b) {
  return (a < b ? a = b, 1 : 0);
}
template <class T, class S>
inline bool chmin(T &a, const S &b) {
  return (a > b ? a = b, 1 : 0);
}

// ? は -1
vc<int> s_to_vi(const string &S, char first_char) {
  vc<int> A(S.size());
  FOR(i, S.size()) { A[i] = (S[i] != '?' ? S[i] - first_char : -1); }
  return A;
}

template <typename T, typename U>
vector<T> cumsum(vector<U> &A, int off = 1) {
  int N = A.size();
  vector<T> B(N + 1);
  FOR(i, N) { B[i + 1] = B[i] + A[i]; }
  if (off == 0) B.erase(B.begin());
  return B;
}

// stable sort
template <typename T>
vector<int> argsort(const vector<T> &A) {
  vector<int> ids(len(A));
  iota(all(ids), 0);
  sort(all(ids),
       [&](int i, int j) { return (A[i] == A[j] ? i < j : A[i] < A[j]); });
  return ids;
}

// A[I[0]], A[I[1]], ...
template <typename T>
vc<T> rearrange(const vc<T> &A, const vc<int> &I) {
  vc<T> B(len(I));
  FOR(i, len(I)) B[i] = A[I[i]];
  return B;
}
#endif
#line 1 "library/other/io.hpp"
// based on yosupo's fastio
#include <unistd.h>

namespace fastio {
#define FASTIO
// クラスが read(), print() を持っているかを判定するメタ関数
struct has_write_impl {
  template <class T>
  static auto check(T &&x) -> decltype(x.write(), std::true_type{});

  template <class T>
  static auto check(...) -> std::false_type;
};

template <class T>
class has_write : public decltype(has_write_impl::check<T>(std::declval<T>())) {
};

struct has_read_impl {
  template <class T>
  static auto check(T &&x) -> decltype(x.read(), std::true_type{});

  template <class T>
  static auto check(...) -> std::false_type;
};

template <class T>
class has_read : public decltype(has_read_impl::check<T>(std::declval<T>())) {};

struct Scanner {
  FILE *fp;
  char line[(1 << 15) + 1];
  size_t st = 0, ed = 0;
  void reread() {
    memmove(line, line + st, ed - st);
    ed -= st;
    st = 0;
    ed += fread(line + ed, 1, (1 << 15) - ed, fp);
    line[ed] = '\0';
  }
  bool succ() {
    while (true) {
      if (st == ed) {
        reread();
        if (st == ed) return false;
      }
      while (st != ed && isspace(line[st])) st++;
      if (st != ed) break;
    }
    if (ed - st <= 50) {
      bool sep = false;
      for (size_t i = st; i < ed; i++) {
        if (isspace(line[i])) {
          sep = true;
          break;
        }
      }
      if (!sep) reread();
    }
    return true;
  }
  template <class T, enable_if_t<is_same<T, string>::value, int> = 0>
  bool read_single(T &ref) {
    if (!succ()) return false;
    while (true) {
      size_t sz = 0;
      while (st + sz < ed && !isspace(line[st + sz])) sz++;
      ref.append(line + st, sz);
      st += sz;
      if (!sz || st != ed) break;
      reread();
    }
    return true;
  }
  template <class T, enable_if_t<is_integral<T>::value, int> = 0>
  bool read_single(T &ref) {
    if (!succ()) return false;
    bool neg = false;
    if (line[st] == '-') {
      neg = true;
      st++;
    }
    ref = T(0);
    while (isdigit(line[st])) { ref = 10 * ref + (line[st++] & 0xf); }
    if (neg) ref = -ref;
    return true;
  }
  template <typename T,
            typename enable_if<has_read<T>::value>::type * = nullptr>
  inline bool read_single(T &x) {
    x.read();
    return true;
  }
  bool read_single(double &ref) {
    string s;
    if (!read_single(s)) return false;
    ref = std::stod(s);
    return true;
  }
  bool read_single(char &ref) {
    string s;
    if (!read_single(s) || s.size() != 1) return false;
    ref = s[0];
    return true;
  }
  template <class T>
  bool read_single(vector<T> &ref) {
    for (auto &d: ref) {
      if (!read_single(d)) return false;
    }
    return true;
  }
  template <class T, class U>
  bool read_single(pair<T, U> &p) {
    return (read_single(p.first) && read_single(p.second));
  }
  template <size_t N = 0, typename T>
  void read_single_tuple(T &t) {
    if constexpr (N < std::tuple_size<T>::value) {
      auto &x = std::get<N>(t);
      read_single(x);
      read_single_tuple<N + 1>(t);
    }
  }
  template <class... T>
  bool read_single(tuple<T...> &tpl) {
    read_single_tuple(tpl);
    return true;
  }
  void read() {}
  template <class H, class... T>
  void read(H &h, T &... t) {
    bool f = read_single(h);
    assert(f);
    read(t...);
  }
  Scanner(FILE *fp) : fp(fp) {}
};

struct Printer {
  Printer(FILE *_fp) : fp(_fp) {}
  ~Printer() { flush(); }

  static constexpr size_t SIZE = 1 << 15;
  FILE *fp;
  char line[SIZE], small[50];
  size_t pos = 0;
  void flush() {
    fwrite(line, 1, pos, fp);
    pos = 0;
  }
  void write(const char val) {
    if (pos == SIZE) flush();
    line[pos++] = val;
  }
  template <class T, enable_if_t<is_integral<T>::value, int> = 0>
  void write(T val) {
    if (pos > (1 << 15) - 50) flush();
    if (val == 0) {
      write('0');
      return;
    }
    if (val < 0) {
      write('-');
      val = -val; // todo min
    }
    size_t len = 0;
    while (val) {
      small[len++] = char(0x30 | (val % 10));
      val /= 10;
    }
    for (size_t i = 0; i < len; i++) { line[pos + i] = small[len - 1 - i]; }
    pos += len;
  }
  void write(const string s) {
    for (char c: s) write(c);
  }
  void write(const char *s) {
    size_t len = strlen(s);
    for (size_t i = 0; i < len; i++) write(s[i]);
  }
  void write(const double x) {
    ostringstream oss;
    oss << fixed << setprecision(15) << x;
    string s = oss.str();
    write(s);
  }
  void write(const long double x) {
    ostringstream oss;
    oss << fixed << setprecision(15) << x;
    string s = oss.str();
    write(s);
  }
  template <typename T,
            typename enable_if<has_write<T>::value>::type * = nullptr>
  inline void write(T x) {
    x.write();
  }
  template <class T>
  void write(const vector<T> val) {
    auto n = val.size();
    for (size_t i = 0; i < n; i++) {
      if (i) write(' ');
      write(val[i]);
    }
  }
  template <class T, class U>
  void write(const pair<T, U> val) {
    write(val.first);
    write(' ');
    write(val.second);
  }
  template <size_t N = 0, typename T>
  void write_tuple(const T t) {
    if constexpr (N < std::tuple_size<T>::value) {
      if constexpr (N > 0) { write(' '); }
      const auto x = std::get<N>(t);
      write(x);
      write_tuple<N + 1>(t);
    }
  }
  template <class... T>
  bool write(tuple<T...> tpl) {
    write_tuple(tpl);
    return true;
  }
  template <class T, size_t S>
  void write(const array<T, S> val) {
    auto n = val.size();
    for (size_t i = 0; i < n; i++) {
      if (i) write(' ');
      write(val[i]);
    }
  }
  void write(i128 val) {
    string s;
    bool negative = 0;
    if (val < 0) {
      negative = 1;
      val = -val;
    }
    while (val) {
      s += '0' + int(val % 10);
      val /= 10;
    }
    if (negative) s += "-";
    reverse(all(s));
    if (len(s) == 0) s = "0";
    write(s);
  }
};
Scanner scanner = Scanner(stdin);
Printer printer = Printer(stdout);
void flush() { printer.flush(); }
void print() { printer.write('\n'); }
template <class Head, class... Tail>
void print(Head &&head, Tail &&... tail) {
  printer.write(head);
  if (sizeof...(Tail)) printer.write(' ');
  print(forward<Tail>(tail)...);
}

void read() {}
template <class Head, class... Tail>
void read(Head &head, Tail &... tail) {
  scanner.read(head);
  read(tail...);
}
} // namespace fastio
using fastio::print;
using fastio::flush;
using fastio::read;

#define INT(...)   \
  int __VA_ARGS__; \
  read(__VA_ARGS__)
#define LL(...)   \
  ll __VA_ARGS__; \
  read(__VA_ARGS__)
#define STR(...)      \
  string __VA_ARGS__; \
  read(__VA_ARGS__)
#define CHAR(...)   \
  char __VA_ARGS__; \
  read(__VA_ARGS__)
#define DBL(...)      \
  double __VA_ARGS__; \
  read(__VA_ARGS__)

#define VEC(type, name, size) \
  vector<type> name(size);    \
  read(name)
#define VV(type, name, h, w)                     \
  vector<vector<type>> name(h, vector<type>(w)); \
  read(name)

void YES(bool t = 1) { print(t ? "YES" : "NO"); }
void NO(bool t = 1) { YES(!t); }
void Yes(bool t = 1) { print(t ? "Yes" : "No"); }
void No(bool t = 1) { Yes(!t); }
void yes(bool t = 1) { print(t ? "yes" : "no"); }
void no(bool t = 1) { yes(!t); }
#line 3 "main.cpp"

void test() {
  vi dp(10);
  dp[0] = 1;
  FOR(i, 1, 10) {
    dp[i] += 2 * dp[i - 1];
    if (i >= 2) {
      FOR(l, i - 1) {
        int r = i - 2 - l;
        dp[i] += dp[l] * dp[r] * 4;
      }
    }
  }
  print(dp[9]);
}

using Re = double;
using ARR = array<Re, 20>;

void solve() {
  LL(N);
  using P = pair<Re, Re>;
  VEC(P, dat, N);

  struct Data {
    string str;
    ARR Y;
  };

  vvc<Data> dp(10);
  {
    Data x;
    x.str = "x";
    FOR(i, N) x.Y[i] = dat[i].fi;
    dp[0].eb(x);
  }

  FOR(i, 1, 10) {
    for (auto&& x: dp[i - 1]) {
      Data sx, cx;
      sx.str = "sin(" + x.str + ")";
      cx.str = "cos(" + x.str + ")";
      FOR(i, N) sx.Y[i] = sin(x.Y[i]);
      FOR(i, N) cx.Y[i] = cos(x.Y[i]);
      dp[i].eb(sx), dp[i].eb(cx);
    }
    if (i >= 2) {
      FOR(l, i - 1) {
        int r = i - 2 - l;
        for (auto&& a: dp[l]) {
          for (auto&& b: dp[r]) {
            Data c1, c2, c3, c4;
            c1.str = "(" + a.str + ")+(" + b.str + ")";
            c2.str = "(" + a.str + ")-(" + b.str + ")";
            c3.str = "(" + a.str + ")*(" + b.str + ")";
            c4.str = "(" + a.str + ")/(" + b.str + ")";
            bool ok = 1;
            FOR(i, N) {
              c1.Y[i] = a.Y[i] + b.Y[i];
              c2.Y[i] = a.Y[i] - b.Y[i];
              c3.Y[i] = a.Y[i] * b.Y[i];
              c4.Y[i] = a.Y[i] / b.Y[i];
              if (abs(b.Y[i]) <= 0.011) ok = 0;
            }
            dp[i].eb(c1);
            dp[i].eb(c2);
            dp[i].eb(c3);
            if (ok) dp[i].eb(c4);
          }
        }
      }
    }
  }

  FOR(cost, 10) {
    for (auto&& x: dp[cost]) {
      bool ok = 1;
      FOR(i, N) {
        Re fx = x.Y[i];
        Re y = dat[i].se;
        Re err = abs(fx - y) / max(1.0, abs(y));
        if (err >= 0.00099) ok = 0;
      }
      if (ok) return print(x.str);
    }
  }
}

signed main() {
  solve();
  return 0;
}

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 100
Accepted
time: 141ms
memory: 150144kb

input:

3
1.000000 1.000000
2.000000 4.000000
3.000000 9.000000

output:

(x)*(x)

result:

ok great!!

Test #2:

score: 0
Accepted
time: 135ms
memory: 150260kb

input:

3
0.618000 1.517072
0.314000 3.132637
1.414000 0.494016

output:

(sin(x))/((x)*(x))

result:

ok great!!

Test #3:

score: 0
Accepted
time: 111ms
memory: 150092kb

input:

5
77.685777 233.057331
-66.445083 -199.335249
79.966717 239.900151
84.982130 254.946390
-31.528900 -94.586700

output:

(x)+((x)+(x))

result:

ok great!!

Test #4:

score: 0
Accepted
time: 133ms
memory: 150044kb

input:

5
25.032427 -0.100652
38.727324 1.658518
27.684334 -0.669555
64.282391 8.275303
52.640700 -0.962660

output:

(sin(x))/(cos(x))

result:

ok great!!

Test #5:

score: 0
Accepted
time: 146ms
memory: 150452kb

input:

5
78.611917 -0.992212
-29.857271 1.011993
-75.513655 1.006611
68.512394 1.145128
7.961096 0.881661

output:

(cos(x))+((sin(x))*(sin(x)))

result:

ok great!!

Test #6:

score: 0
Accepted
time: 97ms
memory: 150132kb

input:

5
-78.733375 0.503570
-20.187183 0.735779
-38.984992 0.730890
47.859232 0.622831
-19.657164 0.641512

output:

sin(sin(cos(cos(x))))

result:

ok great!!

Test #7:

score: 0
Accepted
time: 91ms
memory: 150100kb

input:

5
3.241091 -32.628130
-83.514144 86.463432
33.586619 40.691607
41.123543 -147.352644
26.896326 27.404018

output:

(x)/(sin(x))

result:

ok great!!

Test #8:

score: 0
Accepted
time: 121ms
memory: 149648kb

input:

20
-4.908422 -0.693287
3.569189 0.328182
1.946572 -0.667466
6.515336 -0.829948
-1.394076 0.752980
6.722989 0.831881
1.241795 0.835231
-2.443177 -0.143098
-4.180762 -0.803482
1.511247 0.589509
0.627755 0.554244
-1.865604 -0.470029
-4.756347 -0.656984
1.850611 -0.426016
6.580133 -0.474416
6.861815 -0....

output:

sin(sin((x)/(sin((x)/((x)*(x))))))

result:

ok great!!

Test #9:

score: 0
Accepted
time: 129ms
memory: 148452kb

input:

20
76.797930 0.000002
-76.263778 -0.000002
55.449039 0.000006
10.462093 0.000873
-78.051671 -0.000002
-52.781249 -0.000007
47.053973 0.000010
96.629212 0.000001
-40.697847 -0.000015
31.141805 0.000033
-87.087384 -0.000002
-54.709885 -0.000006
-65.741847 -0.000004
-87.430820 -0.000001
9.420126 0.0011...

output:

(x)/((x)*((x)*((x)*(x))))

result:

ok great!!

Test #10:

score: 0
Accepted
time: 169ms
memory: 149928kb

input:

20
24.490647 23.891773
17.327799 16.329001
21.204241 21.912414
83.489542 84.461510
-55.546573 -54.703972
-7.608368 -8.578356
-3.286697 -3.142101
-66.606831 -66.014954
-44.896454 -45.688502
97.541741 97.389961
-59.986043 -59.694554
57.723989 58.646803
-99.857351 -99.233536
29.134673 28.376609
-98.668...

output:

(x)+(sin(x))

result:

ok great!!

Test #11:

score: 0
Accepted
time: 102ms
memory: 146992kb

input:

20
89.594917 88.596688
-45.187625 -44.253669
97.451471 97.513530
35.078537 35.576300
82.504351 81.771201
-49.755211 -50.243625
-23.019693 -23.876242
-45.247155 -44.293590
75.324114 75.398156
78.533049 78.526282
99.112156 100.100628
31.983437 31.445903
71.251578 70.407388
-44.178279 -43.983549
-25.28...

output:

(x)-(sin(x))

result:

ok great!!

Test #12:

score: 0
Accepted
time: 112ms
memory: 149964kb

input:

20
16.664144 7.850741
44.708237 22.196248
-10.852343 1.533223
-42.713221 -12.119419
-27.815914 -11.038511
31.908696 13.299065
-82.394044 40.761558
-37.317157 -12.907073
-35.369997 17.659068
93.569121 -45.722539
-30.589159 -15.242258
16.180069 6.553209
56.572831 1.366451
99.591187 -47.440823
12.73229...

output:

(x)*((sin(x))*(cos(x)))

result:

ok great!!

Test #13:

score: 0
Accepted
time: 112ms
memory: 148644kb

input:

20
-583.519562 0.000000
-169.653469 0.000000
372.798856 0.000000
180.084282 0.000000
139.388742 0.000000
-648.300263 0.000000
-859.523046 0.000000
-267.278551 0.000000
635.554372 0.000000
299.925737 0.000000
-628.299469 0.000000
169.393099 0.000000
556.144161 0.000000
-881.876627 0.000000
328.692044...

output:

(x)-(x)

result:

ok great!!

Test #14:

score: 0
Accepted
time: 101ms
memory: 150088kb

input:

20
746.491049 746.491049
414.031997 414.031997
-975.051138 -975.051138
45.313068 45.313068
-181.090458 -181.090458
119.607074 119.607074
245.794647 245.794647
-794.156219 -794.156219
461.647608 461.647608
-392.604379 -392.604379
384.522118 384.522118
-461.749513 -461.749513
766.462890 766.462890
244...

output:

x

result:

ok great!!

Test #15:

score: 0
Accepted
time: 134ms
memory: 149676kb

input:

20
4.278335 0.092599
3.559350 0.559919
-2.517239 0.403581
-0.955317 0.182475
3.048015 0.888213
-0.638367 0.393205
-2.188885 0.183959
-0.367275 0.597938
1.106453 0.948186
0.339096 0.971773
-0.678258 0.364003
4.364111 0.060002
-0.671364 0.369012
-2.777257 0.600136
1.617698 0.909755
-3.400784 0.950952
...

output:

sin((sin(x))+((x)/(x)))

result:

ok great!!

Test #16:

score: 0
Accepted
time: 111ms
memory: 148760kb

input:

20
3.692126 -0.260752
0.663419 1.200876
1.167172 0.874743
4.852602 0.631308
3.373109 -0.334749
4.749943 0.529545
-2.549440 -0.245748
-1.158832 0.881804
4.115764 -0.040747
-3.401216 -0.330886
-4.320685 0.119451
-0.070540 1.332133
-4.666465 0.446117
-4.720184 0.499803
-1.731319 0.332854
4.232513 0.046...

output:

(sin(cos(x)))+(sin(sin(cos((x)/(x)))))

result:

ok great!!

Test #17:

score: 0
Accepted
time: 136ms
memory: 149608kb

input:

20
1.462467 0.804429
-2.922001 0.192241
4.580542 -0.620639
-0.475001 -0.799291
-1.988595 -0.234001
1.262913 0.840075
-3.176510 -0.034797
2.030387 0.180297
-3.244547 -0.099928
-3.321420 -0.164361
-0.538138 -0.818609
2.485817 -0.209990
-0.282936 -0.652106
0.964792 0.840607
-1.300754 -0.837872
4.323400...

output:

sin(sin((sin(x))+(sin(sin((x)+(x))))))

result:

ok great!!

Test #18:

score: 0
Accepted
time: 92ms
memory: 79968kb

input:

20
-1.290592 0.818752
0.639318 0.516086
-4.576452 0.791075
2.349231 0.829843
3.053369 0.646833
-4.276424 0.836563
-4.295090 0.835111
1.704429 0.790551
1.694925 0.788364
0.763954 0.527671
-0.477936 0.769603
0.395468 0.525360
0.686854 0.519231
-1.940048 0.637497
2.188388 0.840879
1.028990 0.584344
3.9...

output:

sin(cos(sin((x)+(cos((x)-(x))))))

result:

ok great!!

Test #19:

score: 0
Accepted
time: 111ms
memory: 149436kb

input:

20
-0.425664 0.425664
5.789130 -5.789130
-3.787451 3.787451
0.301151 -0.301151
-8.592688 8.592688
2.669073 -2.669073
5.308311 -5.308311
-0.139985 0.139985
-5.857648 5.857648
-4.992568 4.992568
6.105319 -6.105319
-3.765244 3.765244
5.912188 -5.912188
-6.224392 6.224392
-0.543340 0.543340
3.434037 -3....

output:

(x)-((x)+(x))

result:

ok great!!

Test #20:

score: 0
Accepted
time: 127ms
memory: 150120kb

input:

20
466.316736 -0.978078
-899.828376 0.971830
493.698428 0.451443
543.034476 -0.444891
547.435563 -0.716269
-477.216617 -0.300738
397.144177 -0.964489
-215.994986 0.699650
-125.191685 -0.454687
-278.649888 0.814495
958.350526 0.164022
-505.445050 0.344182
-930.587439 0.625688
397.543136 -0.991345
-25...

output:

sin((x)-((x)+(x)))

result:

ok great!!

Test #21:

score: 0
Accepted
time: 56ms
memory: 80520kb

input:

20
999.999999 0.987127
-999.999999 0.987127
100.000001 -0.333949
-100.000001 -0.333949
999.999998 -0.829877
-999.999998 -0.829877
512.000001 -0.871928
-512.000001 -0.871928
511.999999 -0.985382
-511.999999 -0.985382
0.000000 0.000000
0.000001 0.000000
-0.000001 0.000000
0.180000 0.001050
-0.180000 0...

output:

sin((x)*((x)*((x)*(x))))

result:

ok great!!

Test #22:

score: 0
Accepted
time: 91ms
memory: 80228kb

input:

20
0.009999 0.914653
0.009999 0.914653
0.009999 0.914653
0.009999 0.914653
0.009999 0.914653
0.009999 0.914653
0.009999 0.914653
1.000000 0.914653
1.000000 0.914653
2.005000 0.914653
2.005000 0.914653
3.000000 0.914653
3.000000 0.914653
0.009999 0.914653
0.009999 0.914653
0.009999 0.914653
0.009999 ...

output:

cos(cos(((cos(x))+(cos(x)))/(cos(x))))

result:

ok great!!

Test #23:

score: 0
Accepted
time: 107ms
memory: 149248kb

input:

1
31.424306 31.456129

output:

(x)+(sin(x))

result:

ok great!!

Test #24:

score: 0
Accepted
time: 105ms
memory: 149348kb

input:

20
-29.440025 807.835022
19.414601 415.755934
11.492851 155.071326
18.966989 397.680650
3.027310 15.219226
-4.525550 11.429503
-7.906286 46.696786
-21.105731 403.240419
16.717653 312.915228
25.349563 693.299470
28.071737 844.165892
28.141608 848.233317
-26.371446 642.710272
-13.802857 162.913147
-23...

output:

(x)+((x)+((x)*(x)))

result:

ok great!!

Test #25:

score: 0
Accepted
time: 125ms
memory: 149804kb

input:

20
458.594270 0.909297
236.772098 0.909297
679.844094 0.909297
-113.768271 0.909297
-919.765157 0.909297
450.713950 0.909297
-560.756795 0.909297
35.253093 0.909297
-530.329136 0.909297
-846.165765 0.909297
-294.618124 0.909297
595.795664 0.909297
441.685140 0.909297
220.854674 0.909297
-649.606144 ...

output:

sin(((x)+(x))/(x))

result:

ok great!!

Test #26:

score: 0
Accepted
time: 88ms
memory: 81012kb

input:

4
0.009999 1.000000
1.000000 1.000000
2.000000 1.000000
3.000000 1.000000

output:

cos((x)-(x))

result:

ok great!!

Test #27:

score: 0
Accepted
time: 111ms
memory: 148456kb

input:

4
1.560797 17.311340
1.000000 0.616661
2.000000 -0.369041
3.000000 -0.166678

output:

(cos(sin(x)))/((cos(x))*((x)+(x)))

result:

ok great!!

Test #28:

score: 0
Accepted
time: 127ms
memory: 149280kb

input:

4
0.020000 0.712709
1.000000 0.577284
2.000000 0.964383
3.000000 0.786224

output:

cos(sin((x)+(cos(sin(cos((x)/(x)))))))

result:

ok great!!

Test #29:

score: 0
Accepted
time: 137ms
memory: 150436kb

input:

1
10.000000 9.990000

output:

(x)*(cos((sin(x))/(x)))

result:

ok great!!

Test #30:

score: 0
Accepted
time: 153ms
memory: 149464kb

input:

2
0.026592 0.026593
4.000000 260.000000

output:

(x)+((x)*((x)*((x)*(x))))

result:

ok great!!

Test #31:

score: 0
Accepted
time: 129ms
memory: 149824kb

input:

20
-816.944077 0.750063
364.252903 0.749797
377.702803 0.739860
-64.648254 0.723984
960.420578 0.734135
876.304536 0.749578
-718.016803 0.722938
-720.680010 0.725173
669.591341 0.746462
-835.716345 0.750360
611.456898 0.727346
-401.888640 0.749253
-59.913119 0.749372
-421.048989 0.750298
495.542911 ...

output:

cos(cos(cos(cos(cos(cos(cos(cos(cos(x)))))))))

result:

ok great!!

Test #32:

score: 0
Accepted
time: 140ms
memory: 150412kb

input:

20
-966.243761 0.499984
-775.541582 -0.343886
665.144672 -0.467363
-440.569467 -0.446768
-15.642683 -0.064867
-891.727356 0.368493
-428.695562 -0.501273
-944.141182 -0.501731
265.202915 0.498506
-979.532068 0.423344
-678.301273 0.253567
125.728556 0.064444
-465.052762 -0.095704
-183.526425 -0.498649...

output:

sin(sin(sin(sin(sin(sin(sin(sin(sin(x)))))))))

result:

ok great!!

Test #33:

score: 0
Accepted
time: 151ms
memory: 150060kb

input:

20
167.504612 669.176868
-132.494106 -530.496735
223.716049 894.248735
-14.542026 -59.087262
83.792869 336.028843
46.267758 185.826345
90.986202 364.064505
243.671799 973.706807
176.221425 705.173795
-140.883003 -564.001461
-25.914422 -104.362161
83.745358 335.862277
-92.043462 -367.367900
16.845939...

output:

(x)+((x)+((x)+((x)+(sin(x)))))

result:

ok great!!

Test #34:

score: 0
Accepted
time: 132ms
memory: 148648kb

input:

20
5.820261 -23.727611
89.024912 -355.227137
78.465702 -313.788761
189.581597 -757.441601
-26.277637 104.199881
-58.876286 234.778122
180.037331 -720.972254
57.254054 -228.367888
-180.418016 722.647178
61.635602 -247.473082
126.339101 -504.731198
-192.871864 772.431509
-69.108582 276.440784
20.47183...

output:

(sin(x))-((x)+((x)+((x)+(x))))

result:

ok great!!

Test #35:

score: 0
Accepted
time: 151ms
memory: 149652kb

input:

20
-4.724302 498.103725
-3.940617 172.814337
-2.254073 -20.019734
2.417435 22.626021
4.576524 -434.632501
-3.789730 124.524863
-0.923911 -0.581439
-2.730462 -22.213656
-1.227515 -2.137958
-2.004088 -14.640510
-1.374969 -3.505828
-4.749463 508.486587
-0.919612 -0.568834
-1.895851 -12.242133
2.276076 ...

output:

(x)*((x)*((x)*((x)*(sin(x)))))

result:

ok great!!

Test #36:

score: 0
Accepted
time: 134ms
memory: 149616kb

input:

20
-1.862076 -0.079675
4.978934 -0.001570
-1.706248 -0.116906
3.159038 -0.000175
-2.164361 -0.037776
4.298608 -0.002682
3.437089 -0.002087
0.898312 1.201300
-0.915297 -1.129496
4.614390 -0.002195
0.547090 5.806825
-1.238625 -0.401631
-3.916926 0.002974
-0.651893 -3.359412
-0.913229 -1.137947
-3.8357...

output:

(sin(x))/((x)*((x)*((x)*(x))))

result:

ok great!!

Test #37:

score: 0
Accepted
time: 94ms
memory: 80568kb

input:

20
999.999999 0.987127
-999.999999 0.987127
100.000001 -0.333949
-100.000001 -0.333949
999.999998 -0.829877
-999.999998 -0.829877
512.000001 -0.871928
-512.000001 -0.871928
511.999999 -0.985382
-511.999999 -0.985382
754.901184 0.143249
0.000001 0.000000
-0.000001 0.000000
0.180000 0.001050
-0.180000...

output:

sin((x)*((x)*((x)*(x))))

result:

ok great!!