#include <bits/stdc++.h>
using namespace std;
long n;
vector<long> prec;
int main() {
  ios_base::sync_with_stdio(0);
  prec.push_back(2);
  prec.push_back(7);
  prec.push_back(2);
  prec.push_back(3);
  prec.push_back(3);
  prec.push_back(4);
  prec.push_back(2);
  prec.push_back(5);
  prec.push_back(1);
  prec.push_back(2);
  cin >> n;
  cout << prec[n / 10] * prec[n % 10] << endl;
  cin.get();
  cin.get();
  return 0;
}
