#include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include using namespace std; #define REP(i,m,n) for(int i=(int)(m) ; i < (int) (n) ; ++i ) #define rep(i,n) REP(i,0,n) using ll = long long; const int inf=1e9+7; const ll longinf=1LL<<60 ; const ll mod=998244353; #define pai 3.141592653589793238462643383279 int main(){ int n, k; cin >> n>> k; if(k<=3){ if(n>2*k){ cout << -1 << endl; return 0; } int ans[2*k] = {}; for(int i=k; i<2*k; i++){ ans[i] = 1; } rep(i, n){ cout << ans[i]; } cout << endl; return 0; } int ans[k+2] = {}; rep(i, k+2){ if(i!=0 && i!=k-1 && i!=k) ans[i] = 1; } rep(i, n/(k+2)){ rep(j, k+2){ cout << ans[j]; } } rep(i, n%(k+2)){ cout << ans[i]; } cout << endl; }