#include <bits/stdc++.h>
using namespace std;
const int maxn = 3e3 + 5;
const int inf = 0x3f3f3f3f;
const int mod = 1e9 + 7;
char s[maxn];
vector<int> v[maxn];
int n, k;
void check(int id) {
  for (int i = 0; i <= n - 1; ++i) {
    if (s[i] == 'R' && s[i + 1] == 'L') {
      v[id].push_back(i + 1);
      s[i] = 'L', s[i + 1] = 'R';
      i++;
    }
  }
}
int mink = 0, maxk = 0;
void solve(int ans) {
  int len, id = 0;
  while (1) {
    if (ans == 0) break;
    len = v[id].size();
    for (int i = 0; i <= len - 1; ++i) {
      if (ans == 0) {
        cout << len - i;
        for (int j = 1; j <= len - i; ++j) cout << " " << v[id][i + j - 1];
        cout << '\n';
        break;
      }
      cout << "1 " << v[id][i] << '\n';
      if (i == len - 1) break;
      ans--;
    }
    id++;
  }
  for (int i = id; i < mink; i++) {
    len = v[i].size();
    cout << len;
    for (int j = 0; j <= len - 1; ++j) cout << " " << v[i][j];
    cout << '\n';
  }
}
int main() {
  cin >> n >> k >> s;
  while (mink <= k) {
    check(mink);
    if (v[mink].size() == 0) break;
    maxk += v[mink].size();
    mink++;
  }
  if (mink <= k && maxk >= k) {
    solve(k - mink);
  } else
    cout << "-1\n";
  return 0;
}
