N = int(input())

ans = 0

c = input()
redNum = c.count("R")
leftWhite = c.count("W", 0,redNum)
rightRed = c.count("R", redNum,N)

ans += min(leftWhite, rightRed)
if leftWhite > rightRed:
    ans += (leftWhite - rightRed)

print(ans) N = int(input()) N int(input()) int input() input ans = 0 ans 0 c = input() c input() input redNum = c.count("R") redNum c.count("R") c.count c count "R" leftWhite = c.count("W", 0,redNum) leftWhite c.count("W", 0,redNum) c.count c count "W" 0 redNum rightRed = c.count("R", redNum,N) rightRed c.count("R", redNum,N) c.count c count "R" redNum N ans += min(leftWhite, rightRed) ans min(leftWhite, rightRed) min leftWhite rightRed if leftWhite > rightRed:
    ans += (leftWhite - rightRed) leftWhite > rightRed leftWhite rightRed ans += (leftWhite - rightRed) ans leftWhite - rightRed leftWhite rightRed print(ans) print ans N = int(input()) int(input()) N redNum = c.count("R") c.count("R") redNum ans = 0 0 ans ans += (leftWhite - rightRed) leftWhite - rightRed ans rightRed = c.count("R", redNum,N) c.count("R", redNum,N) rightRed c = input() input() c leftWhite = c.count("W", 0,redNum) c.count("W", 0,redNum) leftWhite ans += min(leftWhite, rightRed) min(leftWhite, rightRed) ans
N = int(input())

ans = 0

c = input()
redNum = c.count("R")
leftWhite = c.count("W", 0,redNum)
rightRed = c.count("R", redNum,N)

ans += min(leftWhite, rightRed)
if leftWhite > rightRed:
    ans += (leftWhite - rightRed)

print(ans)