#include <bits/stdc++.h>
using namespace std;
long long pow(long long x, long long n) {
  long long t = 1;
  while (n) {
    t *= x;
    n--;
  }
  return t;
}
long long s(long long x) {
  long long sum = 0;
  while (x) {
    sum += x % 10LL;
    x /= 10;
  }
  return sum;
}
int main() {
  long long a, b, c;
  cin >> a >> b >> c;
  vector<long long> answer;
  for (long long sx = 0; sx <= 100; ++sx) {
    long long x = b * pow(sx, a) + c;
    if (x > 0 && x < (long long)1e9 && s(x) == sx) answer.push_back(x);
  }
  cout << answer.size() << '\n';
  for (int i = 0; i < answer.size(); ++i) cout << answer[i] << " ";
  return 0;
}
