"use strict";
var __importStar = (this && this.__importStar) || function (mod) {
    if (mod && mod.__esModule) return mod;
    var result = {};
    if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
    result["default"] = mod;
    return result;
};
Object.defineProperty(exports, "__esModule", { value: true });
const fs = __importStar(require("fs"));
const input = fs.readFileSync('/dev/stdin', 'utf8').split('\n');
let h = input[0].split(' ').map(x => +x)[0];
const nums = input[1]
    .split(' ')
    .map(x => +x)
    .sort((a, b) => b - a);
let flag = false;
nums.forEach(n => {
    h -= n;
    if (h <= 0) {
        flag = true;
        return;
    }
});
console.log(flag ? 'Yes' : 'No');
