def a(a1, n)
  return a1 if n == 1
  return n.even? ? a(a1, n - 1) * 2 : a(a1, n - 1) / 3
end

while line = gets
  a1 = line.chomp.to_f
  answer = [*1..10].inject do |answer, n|
    answer += a(a1, n)
  end

  puts sprintf('%.8f', answer)
end