import Control.Monad
import Data.Maybe
import qualified Data.ByteString.Char8 as BS

readInt = fst . fromJust . BS.readInteger
getInt = readInt <$> BS.getLine
-- readIntList = map readInt . BS.words
-- getIntList = readIntList <$> BS.getLine
-- getIntMatrix = map readIntList . BS.lines <$> BS.getContents
main = do
    arg <- getInt
    print (solve arg)


solve :: Integer -> Integer
solve arg = (24 - arg) + 24