#include <bits/stdc++.h>
using namespace std;
const int INF = 2147483647;
const long long LLINF = 9223372036854775807LL;
int digsum(long long x) {
  int ans = 0;
  do {
    ans += x % 10;
    x /= 10;
  } while (x);
  return ans;
}
int main() {
  int a, b, c;
  cin >> a >> b >> c;
  vector<int> v;
  for (int sum = 1; sum <= 100; ++sum) {
    long long curres = b;
    for (int iter = 0; iter < a; ++iter) curres = curres * sum;
    curres += c;
    if (digsum(curres) == sum && curres > 0 && curres < 1000000000)
      v.push_back(curres);
  }
  sort(v.begin(), v.end());
  printf("%d\n", int((v).size()));
  for (int i = 0; i < int((v).size()); ++i) printf("%d ", v[i]);
  return 0;
}
