import           Data.List

fs :: Double -> [Double]
fs a0 = concat $ iterate f [a0, a0 * 2]
  where f (_:an:_) = let an1 = an / 3
                         an2 = an1 * 2
                     in  [an1, an2]

s10 :: Double -> Double
s10 = sum . take 10 . fs

main :: IO ()
main = getContents >>= mapM_ (print . s10 . read) . lines