#include <bits/stdc++.h>
using namespace std;
int main() {
  int A[] = {2, 7, 2, 3, 3, 4, 2, 5, 1, 2};
  int n;
  cin >> n;
  int a = n % 10;
  int b = n / 10;
  int ans = A[a] * A[b];
  cout << ans << endl;
  return 0;
}
