#include <bits/stdc++.h>
unsigned long long p = 1000000007;
unsigned long long exp(unsigned long long num, unsigned long long base) {
  unsigned long long result = 1;
  while (num > 0) {
    if (num % 2 == 1) result = (result * base) % p;
    num = num >> 1;
    base = (base * base) % p;
  }
  return result;
}
int main(int argc, char const* argv[]) {
  unsigned long long p2 = (p + 1) / 2;
  unsigned long long p3 = (p + 1) / 3;
  int n;
  std ::cin >> n;
  unsigned long long* a = new unsigned long long[n];
  unsigned long long* b = new unsigned long long[n];
  bool even = false;
  for (int i = 0; i < n; ++i) {
    std ::cin >> a[i];
    if (a[i] % 2 == 0) even = true;
  }
  b[0] = exp(a[0], 2);
  for (int i = 1; i < n; ++i) {
    b[i] = exp(a[i], b[i - 1]);
  }
  unsigned long long numerator;
  if (!even) {
    if (b[n - 1] < 2) b[n - 1] += p;
    numerator = (((((b[n - 1] - 2) % p) * p2) % p) * p3) % p;
  } else {
    numerator = (((((b[n - 1] + 2) % p) * p2) % p) * p3) % p;
  }
  unsigned long long denom = (((((b[n - 1]) % p) * p2) % p));
  std ::cout << numerator << "/" << denom << std ::endl;
  return 0;
}
