N = int(input())
str = input()

r_sum = 0
for i in range(N):
    if str[i] == "R":
        r_sum += 1
r_sum2 = 0
for i in range(r_sum):
    if str[i] == "R":
        r_sum2 += 1

print(r_sum - r_sum2) N = int(input()) N int(input()) int input() input str = input() str input() input r_sum = 0 r_sum 0 for i in range(N):
    if str[i] == "R":
        r_sum += 1 i range(N) range N if str[i] == "R":
        r_sum += 1 str[i] == "R" str[i] str i "R" r_sum += 1 r_sum 1 r_sum2 = 0 r_sum2 0 for i in range(r_sum):
    if str[i] == "R":
        r_sum2 += 1 i range(r_sum) range r_sum if str[i] == "R":
        r_sum2 += 1 str[i] == "R" str[i] str i "R" r_sum2 += 1 r_sum2 1 print(r_sum - r_sum2) print r_sum - r_sum2 r_sum r_sum2 N = int(input()) int(input()) N r_sum2 = 0 0 r_sum2 str = input() input() str r_sum2 += 1 1 r_sum2 r_sum = 0 0 r_sum r_sum += 1 1 r_sum
N = int(input())
str = input()

r_sum = 0
for i in range(N):
    if str[i] == "R":
        r_sum += 1
r_sum2 = 0
for i in range(r_sum):
    if str[i] == "R":
        r_sum2 += 1

print(r_sum - r_sum2)
