import qualified Data.Map.Strict as Map

main = do
    [rows, columns] <- fmap (fmap read . words) getLine
    allLetters <- buildMap . concat <$> mapM (const getLine) [1..rows]
    let numFours = sum . fmap (`div` 4) $ allLetters
    let numPairs = sum . fmap (`div` 2) $ allLetters
    let neededFours = if rows > 1 && columns > 1 then ((rows * columns - (if odd rows then columns else 0) - (if odd columns then rows else 0)) `div` 4) else 0
    let neededColumnPairs = if odd rows then columns `div` 2 else 0
    let neededRowPairs = if odd columns then rows `div` 2 else 0
    let remainingPairs = numPairs - neededFours * 2
    if numFours >= neededFours && remainingPairs >= (neededColumnPairs + neededRowPairs) 
        then putStrLn "Yes" 
        else putStrLn "No"
    
buildMap = foldl (\m c -> Map.insertWith (+) c 1 m) Map.empty