S = input()
count = 0
max_c = 0

for i in S:
    if i != 'R':
        count = 0
    else:
        count = count + 1
    
    if max_c < count:
        max_c = count
    
print(max_c) S = input() S input() input count = 0 count 0 max_c = 0 max_c 0 for i in S:
    if i != 'R':
        count = 0
    else:
        count = count + 1
    
    if max_c < count:
        max_c = count
     i S if i != 'R':
        count = 0
    else:
        count = count + 1
    
     i != 'R' i 'R' count = 0 count 0 count = count + 1 count count + 1 count 1 if max_c < count:
        max_c = count
     max_c < count max_c count max_c = count max_c count print(max_c) print max_c max_c = 0 0 max_c S = input() input() S max_c = count count max_c count = count + 1 count + 1 count count = 0 0 count count = 0 0 count
S = input()
count = 0
max_c = 0

for i in S:
    if i != 'R':
        count = 0
    else:
        count = count + 1
    
    if max_c < count:
        max_c = count
    
print(max_c)