#include<bits/stdc++.h> using namespace std; int main() { ios::sync_with_stdio(0); cin.tie(0);cout.tie(0); int a,b,cnt=0; cin>>a>>b; for(int i=a;i<=b;i++) { string s=to_string(i); int f=1; for(int j=0;j<s.size();j++) { if(s.find(to_string(j))==s.npos) { f=0; } } if(f==1) { cnt++; //cout<<i<<'\n'; } } cout<<cnt; return 0; }