#include <bits/stdc++.h>
int main(void) {
  int a, i, limit, count;
  while (scanf("%d\n", &a) != EOF) {
    limit = (int)sqrt(a);
    for (i = limit; i >= 2; i--) {
      if (a % i == 0) break;
    }
    if (i == 1) count++;
  }
  printf("%d¥n", count);
  return 0;
}
