N = int(input())
S = list(input())
t1 = S.count('R')
S_R = S[:t1]
t2 = S_R.count('R')
print(t1-t2) N = int(input()) N int(input()) int input() input S = list(input()) S list(input()) list input() input t1 = S.count('R') t1 S.count('R') S.count S count 'R' S_R = S[:t1] S_R S[:t1] S :t1 t1 t2 = S_R.count('R') t2 S_R.count('R') S_R.count S_R count 'R' print(t1-t2) print t1-t2 t1 t2 S = list(input()) list(input()) S t1 = S.count('R') S.count('R') t1 N = int(input()) int(input()) N t2 = S_R.count('R') S_R.count('R') t2 S_R = S[:t1] S[:t1] S_R
N = int(input())
S = list(input())
t1 = S.count('R')
S_R = S[:t1]
t2 = S_R.count('R')
print(t1-t2)