#include <bits/stdc++.h>

int m, d, ans = 0;
int main(){
	scanf("%d%d",&m,&d);
	for(int i=1;i<=d;i++){
		int a = i % 10, b = i / 10;
		if(a < 2 || b < 2) continue;
		int c = a * b;
		if(c <= m) ans ++;
	}
	printf("%d",ans);
	return 0;
}