#include<bits/stdc++.h>
#define rep(i,n)for(int i=0;i<n;i++)
using namespace std;

int cnt[10];
int main() {
	int n;
	while (cin >> n, n) {
		memset(cnt, 0, sizeof(cnt));
		int b = 0;
		rep(i, 100) {
			char c; cin >> c;
			switch (c) {
			case 'M':cnt[i%n]++; break;
			case 'S':b += cnt[i%n] + 1; cnt[i%n] = 0; break;
			case 'L':cnt[i%n] += b + 1; b = 0; break;
			}
		}
		sort(cnt, cnt + n);
		rep(i, n)cout << cnt[i] << ' ';
		cout << b << endl;
	}
}