#include <bits/stdc++.h>
using namespace std;
inline long long pow(long long x, long long y) {
  long long o;
  for (o = 1; y; y >>= 1, x *= x)
    if (y & 1) o *= x;
  return o;
}
inline long long s(long long x) {
  long long o;
  for (o = 0; x; x /= 10) o += x % 10;
  return o;
}
vector<long long> v;
int main(void) {
  long long a, b, c;
  long long i;
  long long x;
  scanf("%I64d %I64d %I64d", &a, &b, &c);
  for (i = 0; i <= 100; i++) {
    x = b * pow(i, a) + c;
    if (x > 0 && x < 1000000000 && s(x) == i) v.push_back(x);
  }
  printf("%d\n", (signed)v.size());
  for (i = 0; i < (signed)v.size(); i++) printf("%I64d ", v.at(i));
  return 0;
}
