#include <bits/stdc++.h>
using namespace std;
int main() {
  int s, w, q, a = 0, t = 0;
  cin >> s;
  w = s / 10;
  q = s % 10;
  if (w == 0) a = 2;
  if (w == 1) a = 7;
  if (w == 2) a = 2;
  if (w == 3) a = 3;
  if (w == 4) a = 3;
  if (w == 5) a = 4;
  if (w == 6) a = 2;
  if (w == 7) a = 5;
  if (w == 8) a++;
  if (w == 9) a = 2;
  if (q == 0) t = 2;
  if (q == 1) t = 7;
  if (q == 2) t = 2;
  if (q == 3) t = 3;
  if (q == 4) t = 3;
  if (q == 5) t = 4;
  if (q == 6) t = 2;
  if (q == 7) t = 5;
  if (q == 8) t++;
  if (q == 9) t = 2;
  cout << t * a << endl;
}
