Problem: Unary is a minimalistic Brainfuck dialect in which programs are written using only one token. 

Brainfuck programs use 8 commands: "+", "-", "[", "]", "<", ">", "." and "," (their meaning is not important for the purposes of this problem). Unary programs are created from Brainfuck programs using the following algorithm. First, replace each command with a corresponding binary code, using the following conversion table: 

  * ">"  →  1000, 
  * "<"  →  1001, 
  * "+"  →  1010, 
  * "-"  →  1011, 
  * "."  →  1100, 
  * ","  →  1101, 
  * "["  →  1110, 
  * "]"  →  1111. 



Next, concatenate the resulting binary codes into one binary number in the same order as in the program. Finally, write this number using unary numeral system — this is the Unary program equivalent to the original Brainfuck one.

You are given a Brainfuck program. Your task is to calculate the size of the equivalent Unary program, and print it modulo 1000003 (106 + 3).

Input

The input will consist of a single line p which gives a Brainfuck program. String p will contain between 1 and 100 characters, inclusive. Each character of p will be "+", "-", "[", "]", "<", ">", "." or ",".

Output

Output the size of the equivalent Unary program modulo 1000003 (106 + 3).

Examples

Input

,.


Output

220


Input

++++[&gt;,.&lt;-]


Output

61425

Note

To write a number n in unary numeral system, one simply has to write 1 n times. For example, 5 written in unary system will be 11111.

In the first example replacing Brainfuck commands with binary code will give us 1101 1100. After we concatenate the codes, we'll get 11011100 in binary system, or 220 in decimal. That's exactly the number of tokens in the equivalent Unary program.

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
const double pi = (2 * acos(0));
struct point {
  long double x, y;
};
double area(int x1, int y1, int x2, int y2, int x3, int y3) {
  double a =
      (x2 * y3) - (x3 * y2) - (x1 * y3) + (x3 * y1) + (x1 * y2) - (x2 * y1);
  a /= 2;
  return fabs(a);
}
long long ncr(long long n, long long r) {
  long long sum = 1;
  long long f = 2;
  for (long long i = n - r + 1; i <= n; i++) {
    sum *= i;
    if (sum % f == 0 && r >= f) sum /= f++;
  }
  if (r >= f) {
    for (long long i = f; i <= r; i++) sum /= i;
  }
  return sum;
}
long double anyarea(point p[], int n) {
  long double sum1 = p[n - 1].x * p[0].y, sum2 = p[n - 1].y * p[0].x;
  for (int i = 0; i < n - 1; i++) {
    sum1 += p[i].x * p[i + 1].y;
    sum2 += p[i].y * p[i + 1].x;
  }
  return fabs((sum1 - sum2) * 0.5);
}
long long fastpow(long long base, long long p, long long m) {
  if (p == 0) return 1;
  long long ans = fastpow(base, p / 2, m);
  ans = ((ans % m) * (ans % m)) % m;
  if (p % 2) ans = ((base % m) * ans) % m;
  return ans;
}
long long GCD(long long M, long long m) {
  if (M % m == 0) return m;
  M %= m;
  long long x1 = M, x2 = m;
  m = min(x1, x2);
  M = max(x1, x2);
  return GCD(M, m);
}
long long lcm(long long M, long long m) {
  return (M * m) / GCD(max(M, m), min(M, m));
}
int main() {
  map<char, string> mp;
  mp['>'] = "1000";
  mp['<'] = "1001";
  mp['+'] = "1010";
  mp['-'] = "1011";
  mp['.'] = "1100";
  mp[','] = "1101";
  mp['['] = "1110";
  mp[']'] = "1111";
  string s1, s;
  cin >> s1;
  for (int i = 0; i < s1.size(); i++) {
    s += mp[s1[i]];
  }
  long long ans = 0;
  int mod = 1000003;
  for (int i = 0; i < s.size(); i++) {
    ans = ((ans % mod) +
           ((s[s.size() - 1 - i] - '0') * (fastpow(2, i, mod))) % mod) %
          mod;
  }
  cout << ans;
}