import Control.Monad
import Data.Maybe
import qualified Data.ByteString.Char8 as BS
import Data.List
import Control.Monad.ST
import Data.Array.ST
import Data.Function

readInt = fst . fromJust . BS.readInt
readIntList = map readInt . BS.words
getInt = readInt <$> BS.getLine
getIntList = readIntList <$> BS.getLine

main = do
    n <- getInt
    (x1:x2:x3:_) <- map (pred . length) . group . sort . ([1,2,3] ++) <$> getIntList
    print $ solve n x1 x2 x3

solve n x1 x2 x3 = runST $ do
    arr <- newArray ((-1,-1,-1),(n+1,n+1,n+1)) 0 :: ST s (STUArray s (Int,Int,Int) Double)
    forM_ [0..x3] $ \k -> do
        forM_ [0..x2+x3-k] $ \j -> do
            forM_ [0..x1+x2+x3-j-k] $ \i -> do
                unless (i+j+k == 0) $ do
                    a1 <- readArray arr (i-1,j,k)
                    a2 <- readArray arr (i+1,j-1,k)
                    a3 <- readArray arr (i,j+1,k-1)
                    let m = i + j + k
                    writeArray arr (i,j,k) $ ((fromIntegral n) + (fromIntegral i) * a1 + (fromIntegral j) * a2 + (fromIntegral k) * a3) / (fromIntegral m)
    ans <- readArray arr (x1,x2,x3)
    return ans