#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b, k, m, n, i;
  long long score, sol;
  scanf("%d%d", &a, &b);
  sol = 1LL * a * a - 1LL * b * b;
  i = 1;
  for (k = 2; k <= b; ++k) {
    if (k - 1 > a) break;
    m = b % k;
    n = b / k;
    score = 0;
    score -= (1LL * n * n * (k - m) + 1LL * (n + 1) * (n + 1) * m);
    score += k - 2;
    score += 1LL * (a - k + 2) * (a - k + 2);
    sol = max(sol, score);
    if (score == sol) i = k;
  }
  cout << sol << "\n";
  if (i == 1) {
    for (i = 0; i < a; ++i) cout << 'o';
    for (i = 0; i < b; ++i) cout << 'x';
    return 0;
  }
  k = i;
  m = b % k;
  n = b / k;
  for (i = 0; i < n; ++i) cout << 'x';
  for (i = 0; i + 1 < (a - k + 2); ++i) cout << 'o';
  for (i = 1; i < (k - m); ++i) {
    cout << 'o';
    for (int j = 0; j < n; ++j) cout << 'x';
  }
  while (m--) {
    cout << 'o';
    for (i = 0; i <= n; ++i) {
      cout << 'x';
    }
  }
  return 0;
}
