#include <bits/stdc++.h>
using namespace std;
long long int sum(long long int d) {
  long long int s = 0;
  while (d) {
    s += d % 10;
    d /= 10;
  }
  return s;
}
long long int power(long long int a, long long int k) {
  long long int fact = 1;
  for (long long int i = 0; i < k; ++i) fact *= a;
  return fact;
}
int main() {
  long long int a, b, c;
  vector<long long int> s;
  cin >> a >> b >> c;
  for (int i = 1; i <= 100; ++i) {
    long long int x = b * power(i, a) + c;
    if (sum(x) == i && x > 0 && x < 1000000000) s.push_back(x);
  }
  cout << s.size() << endl;
  for (int i = 0; i < s.size(); ++i) cout << s[i] << " ";
  return 0;
}
