n = int(input())

c = list(input())

red = c.count('R')
white = n - red
redinred = 0
whiteinred = 0

for i in range(red):
  if c[i] == 'W':
    whiteinred += 1
  else:
    redinred += 1

redinwhite = red - redinred

trade = min(whiteinred, redinwhite)
change = abs(whiteinred - redinwhite)

print(trade + change) n = int(input()) n int(input()) int input() input c = list(input()) c list(input()) list input() input red = c.count('R') red c.count('R') c.count c count 'R' white = n - red white n - red n red redinred = 0 redinred 0 whiteinred = 0 whiteinred 0 for i in range(red):
  if c[i] == 'W':
    whiteinred += 1
  else:
    redinred += 1 i range(red) range red if c[i] == 'W':
    whiteinred += 1
  else:
    redinred += 1 c[i] == 'W' c[i] c i 'W' whiteinred += 1 whiteinred 1 redinred += 1 redinred 1 redinwhite = red - redinred redinwhite red - redinred red redinred trade = min(whiteinred, redinwhite) trade min(whiteinred, redinwhite) min whiteinred redinwhite change = abs(whiteinred - redinwhite) change abs(whiteinred - redinwhite) abs whiteinred - redinwhite whiteinred redinwhite print(trade + change) print trade + change trade change n = int(input()) int(input()) n white = n - red n - red white redinwhite = red - redinred red - redinred redinwhite red = c.count('R') c.count('R') red whiteinred = 0 0 whiteinred redinred = 0 0 redinred whiteinred += 1 1 whiteinred change = abs(whiteinred - redinwhite) abs(whiteinred - redinwhite) change trade = min(whiteinred, redinwhite) min(whiteinred, redinwhite) trade c = list(input()) list(input()) c redinred += 1 1 redinred
n = int(input())

c = list(input())

red = c.count('R')
white = n - red
redinred = 0
whiteinred = 0

for i in range(red):
  if c[i] == 'W':
    whiteinred += 1
  else:
    redinred += 1

redinwhite = red - redinred

trade = min(whiteinred, redinwhite)
change = abs(whiteinred - redinwhite)

print(trade + change)