#include <bits/stdc++.h>
using namespace std;
int main() {
  long long int a, b, c, arr[100] = {0}, i, j, k = 0, num = 1, s, x, sum;
  scanf("%lld%lld%lld", &a, &b, &c);
  for (i = 1; i < 82; i++) {
    sum = 0;
    num = 1;
    for (j = 0; j < a; j++) num *= i;
    s = b * num + c;
    x = s;
    while (x != 0) {
      sum = sum + x % 10;
      x /= 10;
    }
    if (sum == i) {
      if (s > 0 && s < 1000000001) {
        arr[k] = s;
        k++;
      }
    }
  }
  sort(arr, arr + k);
  printf("%lld\n", k);
  for (i = 0; i < k; i++) printf("%lld ", arr[i]);
  return 0;
}
