#include <bits/stdc++.h>
int main(void) {
  int mul[10] = {2, 7, 2, 3, 3, 4, 2, 5, 1, 2};
  int n;
  int ans;
  scanf("%d", &n);
  ans = mul[n / 10] * mul[n % 10];
  printf("%d\n", ans);
  return 0;
}
