s = input()
max_count = 0
count = 0
for i in s:
    if i == "R":
        count += 1
    else:
        max_count = max(max_count, count)
        count = 0
max_count = max(max_count, count)
print(max_count) s = input() s input() input max_count = 0 max_count 0 count = 0 count 0 for i in s:
    if i == "R":
        count += 1
    else:
        max_count = max(max_count, count)
        count = 0 i s if i == "R":
        count += 1
    else:
        max_count = max(max_count, count)
        count = 0 i == "R" i "R" count += 1 count 1 max_count = max(max_count, count) max_count max(max_count, count) max max_count count count = 0 count 0 max_count = max(max_count, count) max_count max(max_count, count) max max_count count print(max_count) print max_count max_count = 0 0 max_count count += 1 1 count s = input() input() s count = 0 0 count count = 0 0 count max_count = max(max_count, count) max(max_count, count) max_count max_count = max(max_count, count) max(max_count, count) max_count
s = input()
max_count = 0
count = 0
for i in s:
    if i == "R":
        count += 1
    else:
        max_count = max(max_count, count)
        count = 0
max_count = max(max_count, count)
print(max_count)