/*
TASK:number
LANG:C++
*/
#include <iostream>
#include <stdio.h>
#include <vector>
#include <string>
#include <math.h>
#include <algorithm>
#include <cstdio>
#define pb push_back
#define FOR(i,n) for(int i=0;i<n;i++)
using namespace std;

int main()
{
    char ans[1001];
    int n,k,d;
    cin >> n >> k >> d;
    int i;
    FOR(i,n)
            ans[i]=0;
    ans[0]=1;
    while (1)
    {
          int j;
          int g=0;
          int br=0;
          char before[1001];
          char checker[1001];
          FOR(i,k)
              before[i]=(char)ans[i];
          FOR(i,n-k)
          {
             for (j=i,g=0;j<i+k;j++,g++)       
                 checker[g]=(char)ans[j];
             if (strcmp(before,checker)==0)
             {
                br=1;
                break;
                }//if
             strcpy(before,checker);
             }//FOR
          if (br==0)
          {
             FOR(i,n)
             {
                     cout << ans[i];
                     }//FOR
             cout << "\n";
             return 0;
             }//if
          else
          {
              FOR(i,n)
              {
                      if(ans[i]!=9){ br=0; break;}
                      }//FOR
              if (br==1){ cout << "0\n"; return 0;}
              else
              {
                  i=n-1;
                  while (ans[i]==9)
                  {
                        ans[i]=0;
                        i--;
                        }//while
                  ans[i]++;
                  }//else
              }//else
          }//FOR
return 0;
}
                        
             
             
