#include <bits/stdc++.h>
using namespace std;
int n, k;
long long maxk = 0, mink = 0, d;
char str[3050];
vector<int> v[3000050];
void solve() {
  int p = 0, p2 = 0, kk = mink;
  while (kk < k) {
    cout << "1 " << v[p][p2] << '\n';
    p2++;
    if (p2 == v[p].size()) {
      p2 = 0;
      p++;
    } else
      kk++;
  }
  cout << v[p].size() - p2;
  for (int i = p2; i < v[p].size(); i++) cout << ' ' << v[p][i];
  cout << '\n';
  p++;
  while (p < mink) {
    cout << v[p].size();
    for (int i = 0; i < v[p].size(); i++) cout << ' ' << v[p][i];
    cout << '\n';
    p++;
  }
}
void check(int p) {
  for (int i = 1; i < n;) {
    if (str[i] == 'R' && str[i + 1] == 'L') {
      str[i] = 'L';
      str[i + 1] = 'R';
      v[p].push_back(i);
      i += 2;
    } else
      i++;
  }
}
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  cin >> n >> k >> (str + 1);
  check(0);
  while (v[mink].size() && mink <= k) {
    maxk += v[mink].size();
    mink++;
    check(mink);
  }
  if (mink <= k && k <= maxk)
    solve();
  else
    cout << "-1\n";
  return 0;
}
