#include <stdio.h>
#include <algorithm>
#include <stdlib.h>
#include <string.h>
#include <queue>
#define rep(i,n) for(int i = 0; i < n; ++i)
#define rrep(i,n) for(int i = 1; i <= n; ++i)
using namespace std;
typedef pair<int,int> P;
const int INF = 1000000000;

int main(){
	int n;
	
	while (true){
		scanf("%d",&n);
		if(n==0)break;
		static int scr[10];
		rep(i,10)scr[i]=0;
		char Huda[114];
		int Ba = 0;
		scanf("%s",Huda);
		
		rep(i,100){
			switch(Huda[i]){
				case 'S':
					Ba += scr[i%n] +1;
					 scr[i%n] = 0;
				break;
				case 'M':
					 scr[i%n]++;
				break;
				case 'L':
					scr[i%n]+=Ba + 1;
					Ba = 0;
				break;
			}
		}
	sort(scr,scr+n);
	rep(i,n)printf("%d ",scr[i]);
	printf("%d\n",Ba);
	}
	return 0;
}