n=int(input())
xu=[list(input().split()) for _ in range(n)]

result = 0
for i in range(n):
  if xu[i][1] == 'JPY':
    result += int(xu[i][0])
  else:
    result += float(xu[i][0]) * 380000
print(result) n=int(input()) n int(input()) int input() input list(input().split()) for _ in range(n) for _ in range(n) _ range(n) range n for _ in range(n) list(input().split()) list input().split() ().split () input split xu=[list(input().split()) for _ in range(n)] xu [list(input().split()) for _ in range(n)] result = 0 result 0 for i in range(n):
  if xu[i][1] == 'JPY':
    result += int(xu[i][0])
  else:
    result += float(xu[i][0]) * 380000 i range(n) range n if xu[i][1] == 'JPY':
    result += int(xu[i][0])
  else:
    result += float(xu[i][0]) * 380000 xu[i][1] == 'JPY' xu[i][1] [i] xu i 1 'JPY' result += int(xu[i][0]) result int(xu[i][0]) int xu[i][0] [i] xu i 0 result += float(xu[i][0]) * 380000 result float(xu[i][0]) * 380000 float(xu[i][0]) float xu[i][0] [i] xu i 0 380000 print(result) print result n=int(input()) int(input()) n result = 0 0 result result += int(xu[i][0]) int(xu[i][0]) result xu=[list(input().split()) for _ in range(n)] [list(input().split()) for _ in range(n)] xu result += float(xu[i][0]) * 380000 float(xu[i][0]) * 380000 result
n=int(input())
xu=[list(input().split()) for _ in range(n)]

result = 0
for i in range(n):
  if xu[i][1] == 'JPY':
    result += int(xu[i][0])
  else:
    result += float(xu[i][0]) * 380000
print(result)