#include <bits/stdc++.h>
using namespace std;
long long pow(long long a, long long b) {
  if (b == 1) return a;
  if (b % 2 == 1)
    return a * pow(a, b - 1);
  else {
    long long cur = pow(a, b / 2);
    return cur * cur;
  }
}
long long a, b, c;
vector<int> out;
void initialization() { cin >> a >> b >> c; }
void solve() {
  for (long long i = 1; i <= 81; ++i) {
    long long cur = b * pow(i, a) + c;
    if (cur >= 1000000000) break;
    long long res = cur;
    long long sum = 0;
    while (cur > 0) {
      sum += cur % 10;
      cur /= 10;
    }
    if (sum == i) out.push_back(res);
  }
}
void print() {
  cout << out.size() << endl;
  for (long long i = 0; i < out.size(); ++i) cout << out[i] << ' ';
}
int main() {
  ios::sync_with_stdio(0);
  initialization();
  solve();
  print();
  return 0;
}
