#include <bits/stdc++.h>
using namespace std;

#define d(x) cerr << #x ":" << x << endl;
#define dd(x, y) cerr << "(" #x "," #y "):(" << x << "," << y << ")" << endl
#define rep(i, n) for (int i = (int)(0); i < (int)(n); i++)
#define repp(i, a, b) for (int i = (int)(a); i < (int)(b); i++)
#define all(v) v.begin(), v.end()
#define dump(v)                  \
    cerr << #v ":[ ";            \
    for (auto macro_vi : v) {    \
        cerr << macro_vi << " "; \
    }                            \
    cerr << "]" << endl;
#define ddump(v)                           \
    cerr << #v ":" << endl;                \
    for (auto macro_row : v) {             \
        cerr << "[";                       \
        for (auto macro__vi : macro_row) { \
            cerr << macro__vi << " ";      \
        }                                  \
        cerr << "]" << endl;               \
    }
using lint       = long long;
const int INF    = 1e9;
const lint LINF  = 1e18;
const lint MOD   = 1e9 + 7;
const double EPS = 1e-10;

int main() {
    int H, W;
    cin >> H >> W;
    vector<string> G(H);
    rep(i, H) cin >> G[i];
    vector<int> NumOf(26, 0);
    rep(i, H) rep(j, W) NumOf[G[i][j] - 'a']++;
    dump(NumOf);

    // int kit4, kit2, kit1;
    // for (int i = 0; i < 26; i++) {
    //     kit4 += NumOf[i] / 4;
    //     NumOf[i] %= 4;
    // }
    // for (int i = 0; i < 26; i++) {
    //     kit2 += NumOf[i] / 2;
    //     NumOf[i] %= 2;
    // }
    // for (int i = 0; i < 26; i++) {
    //     kit1 += NumOf[i] / 1;
    //     NumOf[i] %= 1;
    // }
    dump(NumOf);
    vector<vector<char>> ans(H, vector<char>(W, 'Q'));
    for (int i = 0; i < H / 2; i++) {
        for (int j = 0; j < W / 2; j++) {
            dd(i, j);

            char c;
            bool exist = false;
            for (int i = 0; i < 26; i++) {
                if (NumOf[i] / 4 > 0) {
                    c = (char)'a' + i;
                    NumOf[i] -= 4;
                    exist = true;
                    break;
                }
            }
            if (!exist) {
                dd(i, j);
                cout << "No" << endl;
                return 0;
            }

            int ii    = H - i - 1;
            int jj    = W - j - 1;
            ans[i][j] = c;
            ans[i][j] = ans[i][jj] = ans[ii][j] = ans[ii][jj] = c;
        }
    }
    d("2");
    if (H % 2 == 1) {
        for (int j = 0; j < W / 2; j++) {
            char c;
            bool exist = false;
            for (int i = 0; i < 26; i++) {
                if (NumOf[i] / 2 > 0) {
                    c = (char)'a' + i;
                    NumOf[i] -= 2;
                    exist = true;
                    break;
                }
            }
            if (!exist) {
                cout << "No" << endl;
                return 0;
            }
            int jj        = W - j - 1;
            ans[H / 2][j] = ans[H / 2][jj] = c;
        }
    }
    if (W % 2 == 1) {
        for (int i = 0; i < H / 2; i++) {

            char c;
            bool exist = false;
            for (int i = 0; i < 26; i++) {
                if (NumOf[i] / 2 > 0) {
                    c = (char)'a' + i;
                    NumOf[i] -= 2;
                    exist = true;
                    break;
                }
            }
            if (!exist) {
                cout << "No" << endl;
                return 0;
            }
            int ii = H - i - 1;
            dd(i, ii);
            d(c);
            ans[i][W / 2] = ans[ii][W / 2] = c;
        }
    }
    if (W % 2 == 1 and H % 2 == 1) {
        char c;
        bool exist = false;
        for (int i = 0; i < 26; i++) {
            if (NumOf[i] / 1 > 0) {
                c = (char)'a' + i;
                NumOf[i] -= 1;
                exist = true;
                break;
            }
        }
        if (!exist) {
            cout << "No" << endl;
            return 0;
        }
        ans[H / 2][W / 2] = c;
    }
    // ddump(ans);
    cout << "Yes" << endl;
    return 0;
}

Measured memory_bytes: 256