jiahuimbzuai/CoQuIR huggingface dataset:
//  [java]
import java.util.ArrayList;
import java.util.Collections;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        int n = in.nextInt();
        int x = in.nextInt();

        ArrayList<Integer> m = new ArrayList<>();
        for (int i = 0; i < n; i++) {
            m.add(in.nextInt());
        }

        Collections.sort(m);

        int minimal = m.stream().mapToInt(value -> value).sum();
        int remaining = x - minimal;

        int additional = remaining / m.get(0);

        System.out.println(m.size() + additional);
    }
}
//  [java]
import java.util.Arrays;
import java.util.Scanner;
import java.util.stream.IntStream;

public class Main {

	public static void main(String[] args) {
		try (Scanner scanner = new Scanner(System.in)) {
			int n = scanner.nextInt(), x = scanner.nextInt();
			int[] m = new int[n];
			int sum = IntStream.range(0, n).map(i -> m[i] = scanner.nextInt()).sum();
			int min = Arrays.stream(m).min().getAsInt();
			System.out.println((x - sum) / min + n);
		}
	}
}
//  [cpp]
#include <iostream>
#include <vector>
using namespace std;

int main() {
  int n,x;
  cin >> n >> x;
  vector<int> m(n);
  int min=x;
  int sum=0;
  for (int i=0;i<n;i++) {
	cin >> m.at(i);
	if (m.at(i)<=min) min=m.at(i);
	sum +=m.at(i);
  }
  cout << n + (x-sum)/min <<endl;
}
//  [cpp]
#include <iostream>
#include <math.h>
#include <vector>
#include <map>
#include <stack>
#include <queue>
#include <set>
#include <algorithm>
#include <iomanip>
#include <string.h>

#define FOR(i,a,b) for(int i=(a);i<(b);++i)
#define REP(i,n)  FOR(i,0,n)
#define ALL(a)  (a).begin(),(a).end()

typedef long long lint;

using namespace std;

int main(){
  int N,X;
  cin>>N>>X;
  int mi=1000;
  REP(i,N){
    int m;
    cin>>m;
    X-=m;
    mi=min(m,mi);
  }
  cout<<N+X/mi<<endl;
  return 0;
}
//  [cpp]
#include <iostream>
#include <string>
#include <vector>
#include <algorithm>
using namespace std;

int main() {
  int N, X;
  cin >> N >> X;
  vector<int> m(N);
  for (int i=0; i<N; ++i) {
    cin >> m.at(i);
  }
  
  // 各々1個の合計を求める
  int one_sum = 0;
  for (int i=0; i<N; ++i) {
    one_sum += m.at(i);
  }
  
  // Xからone_sumを引いて，それを最小のmで割って商qを求める
  sort(m.begin(), m.end());
  int q = (X - one_sum) / m.at(0);
  
  // mのサイズにqを加えたものが解
  cout << m.size() + q << endl;
}
//  [cpp]
#include<iostream>
#include <array>
#include <vector>
#include <algorithm>
#include "math.h"
using namespace std;

int main() {
  int N, X;
  vector<int> m;
  cin >> N >> X;
  for (int i=0; i<N; i++) {
    int mm;
    cin >> mm;
    m.push_back(mm);
    X -= mm;
  }
  int cnt = N;
  int min_price = *std::min_element(m.begin(), m.end());
  cnt = cnt + X / min_price;
  std::cout << cnt;
  return 0;
}
//  [cpp]
#include<iostream>
#include<algorithm>
#include<string>
#include<cstdio>

using namespace std;
int main(void) {
  int n, x;
  int a[100]={0};
  cin>>n>>x;
  for(int i=0; i<n; i++) {
    cin>>a[i];
    x-=a[i];
  }
  sort(a, a+n);
  // cout<<x<<" "<<a[0]<<endl;
  cout<<n+(x/a[0])<<endl;
  return 0;
}
//  [cpp]
#include <bits/stdc++.h>
using namespace std;

using int32 = int_fast32_t;
using int64 = int_fast64_t;

const int32 INF = 1e9;
const int32 MOD = 1e9+7;
const int64 LLINF = 1e18;

#define YES(n) cout << ((n) ? "YES\n" : "NO\n"  )
#define Yes(n) cout << ((n) ? "Yes\n" : "No\n"  )
#define ANS(n) cout << (n) << "\n"
#define REP(i,n) for(int64 i=0;i<(n);++i)
#define FOR(i,a,b) for(int64 i=(a);i<(b);i++)
#define FORR(i,a,b) for(int64 i=(a);i>=(b);i--)
#define ALL(obj) (obj).begin(),(obj).end()
#define pii pair<int32,int32>
#define pll pair<int64,int64>
#define pb(a) push_back(a)
#define mp make_pair

int main(){
    cin.tie(0);
    ios::sync_with_stdio(false);
    int32 n, x;
    cin >> n >> x;
    vector<int32> m(n);
    REP(i,n){
        cin >> m[i];
        x -= m[i];
    }
    vector<int32> dp(x+1, 0);
    REP(i,n){
        REP(j,x+1-m[i]){
            dp[j+m[i]] = max(dp[j+m[i]], dp[j] + 1);
        }
    }
    int32 ans = 0;
    REP(i,x+1)ans = max(ans, dp[i]);
    ans += n;
    ANS(ans);
    return 0;
}
//  [c]
#include<stdio.h>
int main(void){
  int n ,x ,i ,min = 1000 ,count = 0;
  scanf("%d %d",&n ,&x);

  int m[n];
  for(i = 0; i < n; i++){
    scanf("%d",&m[i]);
    min = (min < m[i]) ? min : m[i];
    x -= m[i];
    count ++;
  }
  while(x > 0){
    x -= min;
    if(x >= 0){
      count ++;
    }
  }
  printf("%d",count);

  return 0;
}
//  [c]
#include <stdio.h>

int main(){
  int i, N, X, m, sum=0, min;
  scanf("%d %d", &N, &X);
  for(i=0;i<N;i++){
    scanf("%d",&m);
    if(i==0) min=m;
    sum+=m;
    if(min>m) min=m;
  }
  printf("%d\n", N+(X-sum)/min);
  return 0;
}
//  [c]
#include <stdio.h>
#include <string.h>

int main(void){
    int N;
    int X;
    int sum = 0;
    int min;
    double result;
    int kekka;

    

    scanf("%d %d",&N,&X);
    if(N < 2 || N > 100){
        return 0;
    }
    

    int m[101];

    for(int i = 0; i < N; i++){
        scanf("%d",&m[i]);
    }

	min = m[0];
    for(int i = 0; i < N; i++){
        if(m[i] <= min){
            min = m[i];
            //printf("%d\n",min);
        }
    }

    for(int i= 0;i < N; i++){
        sum = sum + m[i];
        //printf("%d\n",sum);
    }

    if(sum <= X){
       result = (X - sum) / min;
       //printf("%lf\n",result);
    }else{
        return 0;
    }
    kekka = (int)result + N;
     printf("%d\n",kekka);
    }
//  [c]
#include<stdio.h>
#include<stdlib.h>
int main()
{
	int i = 0, j = 0;
	int sum = 0;
	int a[100];
	int n, x;
	scanf("%d%d", &n, &x);
	for (i = 0; i < n; i++)
		scanf("%d", &a[i]);
	for (i = 0; i < n; i++)
		sum += a[i];
	int t = x - sum;
	for (i = 0; i<n-1; i++) 
		for (j = 0; j<n - i - 1; j++)
			if (a[j]>a[j + 1])
			{
				int temp = a[j];
				a[j] = a[j + 1];
				a[j + 1] = temp;
			}
		t = t / a[0];
		printf("%d", t + n);
	return 0;
}
//  [c]
#include<stdio.h>
#define size 200


int main( )
{
    int n , num[size] , i , j , count= 0 , sum , x , max , k ;
    
    scanf("%d%d" , &n , &x);
    for( i = 1 , sum = 0; i <= n ; i++)
    {
        scanf("%d" , &num[i] );
        sum += num[i] ;
    }
    
    if( (sum-x) == 0)
        printf("%d\n" , n);
        
    else 
    {
        sum = x- sum ;
        i = 1 ;
        max = 0 ;
        for( i = 1 ; i <= n ; i++)
        {
            k = sum ;
            count = 0 ;
            while( k)
            {
                k = k - num[i] ;
                count++ ;
                if( k < num[i])
                    break ;
            }
            if( count >= max)
                max = count ;
        }
        printf("%d\n" , max+n);
    }
    
    return 0;    
}
//  [c]
#include<stdio.h>

int main()
{
  int N,X;
  int m[101];
  int i;
  int a,b;
  scanf("%d",&N);
  scanf("%d",&X);
  scanf("%d",&m[0]);
  a=m[0];
  X-=m[0];
  for(i=1;i<N;i++){
    scanf("%d",&m[i]);
    X-=m[i];
    if(m[i]<a) a=m[i];
  }
  b=X/a;
  printf("%d",N+b);
  return 0;
}
//  [javascript]
'use strict'

function Main(input) {
    const split_input = input.split("\n");
    const n = parseInt(split_input[0].split(' ')[0]);
    const x = split_input[0].split(' ')[1];
    const prices = [];
    let sum = 0;
    for (let index = 1; n > prices.length; index++) {
        let price = parseInt(split_input[index]);
        prices.push(price);
        sum += price;
    }
    const min_price = prices.reduce((a, b) => a < b ? a : b);

    console.log(n + Math.floor((x - sum) / min_price));
}
Main(require("fs").readFileSync("/dev/stdin", "utf8"));
//  [javascript]
"use strict";

const main = arg => {
    const N = parseInt(arg.split("\n")[0].split(" ")[0]);
    let   X = arg.split("\n")[0].split(" ")[1];
    const m = arg.split("\n").slice(1, N + 1).map(n=>parseInt(n));
    
    X = (X - m.reduce((m,n)=>m+n));
    
    console.log(Math.floor(X / Math.min(...m)) + N);
}
main(require('fs').readFileSync('/dev/stdin', 'utf8'));
//  [javascript]
'use strict'

function main(input) {
    
        input = input.split(/\n|\s/).map(v => ~~v)
        const q = input[1]
        const tmp = input.slice(2, -1)
        const recipe = tmp.sort((a, b) => a - b)

        const sum = recipe.reduce((v, x) => v + x)

        const ans = Math.floor((q - sum) / recipe[0]) + recipe.length
        

        console.log(ans)



}
main(require("fs").readFileSync("/dev/stdin", "utf8"));
//  [javascript]
function Main(s) {
  s = s.split("\n");
  s[0] = s[0].split(" ");
  const n = +s[0][0];
  const x = +s[0][1];
  var sum = 0;
  var min = 1e9;
  for(var i = 0; i < n; i++){
    sum += +s[i+1];
    min = Math.min(min, +s[i+1])
  }
  console.log(n + Math.floor((x - sum) / min));
}
Main(require("fs").readFileSync("/dev/stdin","utf8"));
//  [javascript]
'use strict'
 
function main(s) {
 
  s = s.split('\n');
  const n = Number(s[0].split(' ')[0]);
  const x = Number(s[0].split(' ')[1]);
  const donuts = s.slice(1, -1).map(el => Number(el));
 
  donuts.sort((a, b) => a - b);
  const sum = donuts.reduce((a, b) => a + b);
  const ans = Math.floor((x - sum) / donuts[0]) + donuts.length;
 
  console.log(ans);
}
 
main(require("fs").readFileSync("/dev/stdin", "utf8"));
//  [javascript]
function Main(input) {
  var inputs = input.split("\n");
  var n_x = inputs[0].split(" ").map(e => parseInt(e, 10));
  var m = inputs.slice(1).filter(e => e).map(e => parseInt(e, 10));
  var sum = m.reduce((acc, cur) => acc + cur);
  var min = Math.min(...m);
  var cnt = m.length;
  var g = 0;
  var x = n_x[1] - sum;

  while(g <= x) {
    g += min;
    cnt += 1;
  }
  console.log(cnt - 1);
}

Main(require("fs").readFileSync("/dev/stdin", "utf8"));
//  [go]
package main

import (
	"fmt"
)

func main() {
	var n, x, m int
	fmt.Scan(&n, &x)
	l := 1001
	for i := 0; i < n; i++ {
		fmt.Scan(&m)
		x -= m
		if l > m {
			l = m
		}
	}
	fmt.Println(x/l + n)
}
//  [go]
package main

import (
  "fmt"
)

func sumInt(a ...int) int {s := 0; for _, v := range a {s += v}; return s}
func maxInt(a ...int) int {m := a[0]; for _, x := range a {if x > m {m = x}}; return m}
func minInt(a ...int) int {m := a[0]; for _, x := range a {if x < m {m = x}}; return m}

func main() {
  var n, x int 
  fmt.Scan(&n, &x)
  m := make([]int, n)
  for i := 0; i < n; i++ {
    fmt.Scan(&m[i])
  }
  cnt := n
  x -= sumInt(m...)
  cnt += x / minInt(m...)
  fmt.Println(cnt)

}
//  [go]
package main

import (
  "fmt"
)

func main() {
  var N, X , min int
  fmt.Scan(&N, &X)
  // Mを入力する
  M := make([]int, N)
  for i, _ := range M {
    fmt.Scan(&M[i])
  }
  // TODO: 最小値を求める
  min = M[0]
  for _, v := range M {
    if (v < min) {
      min = v
    }
  }
  // 1つずつ足していった場合
  var sum int
  for _, i := range M {
    sum = sum + i
  }

  // ドーナツの粉の残りを求める = amari
  amari := X - sum
  count := amari / min
  fmt.Println(count + N)

}
//  [go]
package main
import (
  "fmt"
)
 
func main(){
  var n, g, a, sum, small int
  fmt.Scan(&n)
  fmt.Scan(&g)
  costs := make([]int, n)
  count := n
  for i:= 0; i < n; i++ {
    fmt.Scan(&a)
    sum += a
    if a < small || small == 0 {
      small = a
    }
    costs[i] = a
  }
  g = g - sum
  for g >= small {
    count++
    g -= small
  }
  fmt.Printf("%d\n", count)
}
//  [go]
package main

import "fmt"

func main() {
	// Code for B - Bitter Alchemy
	var N, X int
	fmt.Scanf("%d %d", &N, &X)

	var m, sum int
	var min int = 1000
	for i := 0; i < N; i++ {
		fmt.Scanf("%d", &m)
		sum += m
		if min > m {
			min = m
		}
	}

	fmt.Println(N + (X-sum)/min)
}
//  [go]
package main

import (
	"bufio"
	"fmt"
	"os"
	"strconv"
)

var sc = bufio.NewScanner(os.Stdin)

func Scan() string {
	sc.Scan()
	return sc.Text()
}

func iScan() int {
	n, _ := strconv.Atoi(Scan())
	return n
}

func fScan() float64 {
	n, _ := strconv.ParseFloat(Scan(), 64)
	return n
}
func stringToInt(s string) int {
	n, _ := strconv.Atoi(s)
	return n
}
func SScan(n int) []string {
	a := make([]string, n)
	for i := 0; i < n; i++ {
		a[i] = Scan()
	}
	return a
}
func iSScan(n int) []int {
	a := make([]int, n)
	for i := 0; i < n; i++ {
		a[i] = iScan()
	}
	return a
}
func abs(x int) int {
	if x < 0 {
		x = -x
	}
	return x
}
func larger(a, b int) int {
	if a < b {
		return b
	} else {
		return a
	}
}
func smaller(a, b int) int {
	if a > b {
		return b
	} else {
		return a
	}
}
func max(a []int) int {
	x := a[0]
	for i := 0; i < len(a); i++ {
		if x < a[i] {
			x = a[i]
		}
	}
	return x
}
func min(a []int) int {
	x := a[0]
	for i := 0; i < len(a); i++ {
		if x > a[i] {
			x = a[i]
		}
	}
	return x
}
func sum(a []int) int {
	x := 0
	for _, v := range a {
		x += v
	}
	return x
}

var mod int = 1000000007

func main() {
	buf := make([]byte, 0)
	sc.Buffer(buf, mod)
	sc.Split(bufio.ScanWords)
	n := iScan()
	x := iScan()
	m := iSScan(n)
	fmt.Println((x-sum(m))/min(m) + n)
}
//  [ruby]
n, x = gets.split(" ").map(&:to_i)
m = Array.new(n){gets.to_i}.sort
ans = 0
m.each do |i|
  if x >= i
    x -= i
    ans += 1
  else
    break
  end
end
puts ans + x / m[0]
//  [ruby]
n, x = gets.split.map(&:to_i)
lines = readlines.map(&:to_i)

puts (x - lines.inject(:+)) / lines.min + n
//  [ruby]
N, X = gets.split.map(&:to_i)
ary = N.times.map{gets.to_i}.sort
x = X
total = 0
ary.each_with_index do |m, i|
    sum = i < ary.size - 1 ? ary[i+1..-1].inject(:+) : 0
    cnt = (x - sum).div(m)
    total += cnt
    x -= m * cnt
end
puts total
//  [ruby]
n, x = gets.split.map(&:to_i)

ms = []
n.times { ms << gets.to_i }

ret = 0
ret += n

(1..x).each do |i|
  break unless x - ms.inject(:+) - ms.min * i >= 0
  ret += 1
end

puts ret
//  [ruby]
n, x = gets.split.map(&:to_i)
m = []
for i in 0...n
	m[i] = gets.to_i
end
a = x - m.inject(:+)
cnt = n
while(a / m.min > 0)
	a -= m.min
	cnt += 1
end
puts cnt
//  [ruby]
n,x = gets.split.map(&:to_i)
i_n = n.times.map{ gets.to_i}

rmd = x - i_n.inject(0){|sum,num| sum += num }

counter = 0
while rmd >= i_n.min
  rmd = rmd - i_n.min
  counter += 1
end

puts counter + n
//  [rust]
macro_rules! input {
    (source = $s:expr, $($r:tt)*) => {
        let mut iter = $s.split_whitespace();
        input_inner!{iter, $($r)*}
    };
    ($($r:tt)*) => {
        let mut s = {
            use std::io::Read;
            let mut s = String::new();
            std::io::stdin().read_to_string(&mut s).unwrap();
            s
        };
        let mut iter = s.split_whitespace();
        input_inner!{iter, $($r)*}
    };
}

macro_rules! input_inner {
    ($iter:expr) => {};
    ($iter:expr, ) => {};

    ($iter:expr, $var:ident : $t:tt $($r:tt)*) => {
        let $var = read_value!($iter, $t);
        input_inner!{$iter $($r)*}
    };
}

macro_rules! read_value {
    ($iter:expr, ( $($t:tt),* )) => {
        ( $(read_value!($iter, $t)),* )
    };

    ($iter:expr, [ $t:tt ; $len:expr ]) => {
        (0..$len).map(|_| read_value!($iter, $t)).collect::<Vec<_>>()
    };

    ($iter:expr, chars) => {
        read_value!($iter, String).chars().collect::<Vec<char>>()
    };

    ($iter:expr, usize1) => {
        read_value!($iter, usize) - 1
    };

    ($iter:expr, $t:ty) => {
        $iter.next().unwrap().parse::<$t>().expect("Parse error")
    };
}
fn main() {
    input! {
        n: u32,
        x: u32,
        m: [u32; n],
    };
    println!("{}", n + (x - m.iter().sum::<u32>()) / m.iter().min().unwrap());
}
//  [rust]
use std::io;
use std::cmp::min;

fn procon_read<T: std::str::FromStr>() ->  Vec<T> {
	let mut buf = String::new();
	io::stdin().read_line(&mut buf).expect("");
	let iter = buf.split_whitespace();
	let mut v: Vec<T> = Vec::new();
	for i in iter {
		v.push(i.parse().ok().unwrap());
	}
	v
}

fn main() {
	let v:Vec<i32> = procon_read();
	let n = v[0];
	let x = v[1];
	let mut m:Vec<i32> = Vec::new();
	let mut sum = 0;
	for i in 0..n {
		let v:Vec<i32> = procon_read();
		sum += v[0];
		m.push(v[0]);
	}
	let mut mini = 1000;
	for i in m {
		mini = min(mini, i);
	}
	println!("{}", n + (x - sum)/mini);
}
//  [rust]
use std::io::*;
use std::str::FromStr;

pub fn read<T: FromStr>() -> T {
    let stdin = stdin();
    let stdin = stdin.lock();
    let token: String = stdin
        .bytes()
        .map(|c| c.expect("failed to read char") as char)
        .skip_while(|c| c.is_whitespace())
        .take_while(|c| !c.is_whitespace())
        .collect();
    token.parse().ok().expect("failed to parse token")
}

fn main() {
    let n: usize = read();
    let mut x: usize = read();
    let mut minv = std::usize::MAX;

    for _ in 0..n {
        let mi = read();
        x -= mi;
        if mi < minv {
            minv = mi;
        }
    }
    println!("{}", n + (x / minv));
}
//  [rust]
use proconio::input;
#[allow(unused_imports)]
use proconio::marker::{Bytes, Chars};
#[allow(unused_imports)]
use std::cmp::{min, max};

fn main() {
	input! {
		n: usize,
		x: usize,
		mut m: [usize; n],
	}

	let mut sum = 0;
	let mut mmin = 9999;
	for i in 0..n {
		sum += m[i];
		mmin = min(mmin, m[i]);
	}
	println!("{}", (x-sum)/mmin+n);
}
//  [rust]
use proconio::*;

fn main() {
    input! {
    a:usize,
    b:usize,
    v:[usize;a]
    }
    let sum:usize=v.iter().sum();
    let min:usize=*v.iter().min().unwrap();
    println!("{}",a+(b-sum)/min);
}
//  [rust]
use proconio::{fastout, input};
#[allow(unused_mut)]
#[fastout]
fn main() {
    input! {
        n: usize,
        x: usize,
        m: [usize; n]
    }
    let m: Vec<usize> = m;
    let sum: usize = m.iter().sum();
    let min = *m.iter().min().unwrap();
    let remain = x - sum;
    println!("{}", n + remain / min);
}
//  [swift]
let a = readLine()!.split(separator: " ").map({Int($0)!})
var arr = [Int]()
let N = a[0]
let X = a[1]

for i in 0 ..< N {
    arr.append(Int(readLine()!)!)
}
var sum = arr.reduce(0, +)
var min = arr.min() ?? 0
print((X - sum)/min+N)
//  [swift]
import Foundation
func toTuple<T>(_ args: [T]) -> (T, T) { (args[0], args[1]) }
func readInts() -> [Int] { readLine()!.split(separator: " ").map { Int($0)! } }

var (n, x) = toTuple(readInts())
var mi: [Int] = []
var ans = 0
for _ in 0..<n { mi.append(Int(readLine()!)!) }
let sum = mi.reduce(0) { $0 + $1 }
x -= sum
ans += n + (x / mi.min()!)
print(ans)
//  [swift]
import Foundation


func readStr() -> String {
  return readLine()!
}

func readInt() -> Int {
    return Int(readLine()!)!
}

func readInts() -> [Int] {
    return readLine()!.split(separator: " ").map { Int($0)! }
}

func readTwoInts() -> (a: Int, b: Int) {
    let ints = readLine()!.split(separator: " ").map { Int($0)! }
    return (a: ints[0], b: ints[1])
}

var (N, X) = readTwoInts()
var mn = 10000000087
for _ in 0..<N {
    let m = readInt()
    X -= m
    mn = min(mn, m)
}

if X >= mn {
    N += X / mn
    print(N)
} else {
    print(N)
}
//  [swift]
import Foundation

#if swift(>=4.0)
extension String {
    func split(by separator: String) -> [String] {
        return self.components(separatedBy: separator)
    }
    func toArray() -> [String] {
        return self.map{String($0)}
    }
}
#else
extension String {
    func split(by separator: String) -> [String] {
        return self.componentsSeparatedByString(separator)
    }
    var count: Int {
        return self.characters.count
    }
    func toArray() -> [String] {
        return self.characters.map{String($0)}
    }
    func uppercased() -> String {
        return self.uppercaseString
    }
    func lowercased() -> String {
        return self.lowercaseString
    }
}
//extension Array where Element == String {
//    func joined(separator separator: String) -> String {
//        return self.joinWithSeparator(separator)
//    }
//}
extension Array where Element: Comparable {
    func max() -> Element {
        return self.maxElement()!
    }
    func min() -> Element {
        return self.minElement()!
    }
    func sorted() -> Array {
        return self.sort()
    }
    func reversed() -> Array {
        return self.reverse()
    }
    mutating func sort() {
        self.sortInPlace()
    }
}
extension Array {
    init(repeating: Element, count: Int) {
        self.init(count: count, repeatedValue: repeating)
    }
}
func stride<T: Strideable>(from start: T, to end: T, by stride: T.Stride) -> StrideTo<T> {
    return start.stride(to: end, by: stride)
}
#endif
func readInt() -> Int? {
    return Int(readLine()!)
}
func readStringSplit(by separator: String) -> [String] {
    return readLine()!.split(by: separator)
}
func readIntSplit(by separator: String) -> [Int] {
    return readLine()!.split(by: separator).map{Int($0)!}
}
func exponentiate(_ lhs: Int, _ rhs: Int) -> Int {
    return (0..<rhs).reduce(1){i,_ in i*lhs}
}

/*************** テストスペース ***************/



/*************** メインプログラム ***************/

let input = readIntSplit(by: " ")
let (N, X) = (input[0], input[1])
var m = [Int]()
for _ in 0..<N {
    m += [readInt()!]
}
print(N + (X-m.reduce(0){$0+$1})/m.min())
//  [typescript]
const log = console.log;

const parseLines = (s: string) => s.trim().split("\n");
const parseSpaceSeparated = (line: string) => line.trim().split(" ");
const parseDecimalInt = (s: string) => parseInt(s);
const parseSpaceSeparatedDecimalInt = (line: string) =>
  parseSpaceSeparated(line).map(parseDecimalInt);

const sumReducer = (accumulator: number, currentValue: number) =>
  accumulator + currentValue;
const sum = (numbers: number[]) => numbers.reduce(sumReducer, 0);

// ----

function Main(input: string): void {
  const [head, ...body] = parseLines(input);
  const [n, x] = parseSpaceSeparatedDecimalInt(head);
  const m = body.map(parseDecimalInt);

  let donutsCount = m.length;
  const usedPowderWeight = sum(m);
  const minM = Math.min(...m);

  donutsCount += ((x - usedPowderWeight) / minM) | 0;

  log(donutsCount);
}

Main(require("fs").readFileSync("/dev/stdin", "utf8"));
//  [typescript]
import * as fs from 'fs';

namespace AtCoder.abc095 {
    class ProgramB {
        args: string[];

        // 3 1000
        // 120
        // 100
        // 140
        //
        // 6
        constructor(args: string[]) {
            this.args = args;
        }

        main() {
            const _args = this.args;
            let [n, x]: number[] = _args[0].split(' ').map(Number);
            _args.shift();
            const m: number[] = _args.map(Number);
            m.sort((a: number, b: number) => a - b);

            let ans: number = m.reduce((acc: number, cuu: number) => {
                if (x >= cuu) {
                    acc++;
                    x -= cuu;
                }
                return acc;
            }, 0);

            while (x > 0 && x >= m[0]) {
                ans++;
                x -= m[0];
            }

            console.log(ans);
        }
    }

    const args: string[] = fs.readFileSync('/dev/stdin', 'utf8').trim().split('\n');
    new ProgramB(args).main();
}
//  [typescript]
const stdin = require('fs').readFileSync('/dev/stdin', 'utf8').trim()

const [n, _x] = stdin
  .split('\n')[0]
  .split(' ')
  .map(Number)

const [, ...m] = stdin.split('\n').map(Number)

const ans = () => {
  const ms = m.sort((a, b) => a - b)

  let x = _x

  let count = 0

  for (let i = 0; i < n; i++) {
    x -= ms[i]

    if (x >= 0) {
      count++
    } else {
      return count
    }
  }

  return count + Math.floor(x / ms[0])
}

console.log(ans())
//  [typescript]
const input=require('fs').readFileSync('/dev/stdin','utf8').split(/[\s]/);const tn=():number=>{const a=input[0];input.shift();return Number(a)};const tnn=(n:number):number[]=>{const a=[];for(let i=0;i<n;i++){a.push(tn())}return a};const ts=():string=>{const a=input[0];input.shift();return String(a)};const tss=(n:number):string[]=>{const a=[];for(let i=0;i<n;i++){a.push(ts())}return a};const tc=():string=>{let a=input[0].split('');const b=a[0];a.shift();if(a.length>0){input[0]=a.join('')}else{input.shift()}return String(b)};const tcc=(n:number):string[]=>{const a=[];for(let i=0;i<n;i++){a.push(tc())}return a};const to=(...arg)=>{console.log(...arg)};const abs=(a)=>{return Math.abs(a)};const min=(...a)=>{return Math.min(...a)};const max=(...a)=>{return Math.max(...a)};const floor=(a)=>{return Math.floor(a)};const asc=(ar:number[])=>{return ar.sort((a,b)=>{return a-b})};const desc=(ar:number[])=>{return ar.sort((a,b)=>{return b-a})};const sw=(a,arr:any[],op:'=='|'>='|'>'|'<='|'<'='==')=>{for(let i=0;i<arr.length-1;i+=2){if(eval(a+op+arr[i])){return arr[i+1];}}return arr[arr.length-1]};const near=(n:number,arr:number[]):number=>{let ne=arr[0],ni=0;for(let i=1;i<arr.length;i++){if(Math.abs(n-ne)>Math.abs(n-arr[i])){ne=arr[i];ni=i}}return ni};
const main=()=>{
  let [a,b]=tnn(2)
  let d=tnn(a)
  for(let i=0;i<a;i++)b-=d[i]
  while(true){
    b-=min(...d)
    if(b>=0)a++
    if(b<=0){
      to(a)
      return
    }
  }
}
main()
//  [typescript]
var lines: string[] = [];
var reader: any = require("readline").createInterface({
  input: process.stdin,
  output: process.stdout
});
reader.on("line", function(line: string) {
  lines.push(line);
});

reader.on("close", function() {
  // N X
  var numbers: number[] = lines[0].split(" ").map(x => {
    return Number(x);
  });
  var numD: number = Number(numbers[0]);
  var numX: number = Number(numbers[1]);

  var total: number = numX;
  var min: number = numX;

  for (var i: number = 1; i < lines.length; i++) {
    total = total - Number(lines[i]);
    if (Number(lines[i]) < min) {
      min = Number(lines[i]);
    }
  }

  console.log(lines.length - 1 + Math.floor(total / min));
});
//  [typescript]
import { readFileSync } from "fs";

const read = () =>
  readFileSync(0, "utf8")
    .split("\n")
    .map((line) => line.split(" "));

const main = (input: string[][]) => {
  const [N, X] = input[0].map(Number);
  const M = input.slice(1, -1).map((line) => Number(line[0]));

  const sum = M.reduce((acc, cur) => acc + cur);

  return N + Math.floor((X - sum) / Math.min(...M));
};

console.log(main(read()));
//  [python]
import sys
sys.setrecursionlimit(10 ** 7)
read = sys.stdin.buffer.read 
input = sys.stdin.buffer.readline
def inputS(): return input().rstrip().decode()
readlines = sys.stdin.buffer.readlines 

H, N = map(int, input().split())
A = sum(map(int, input().split()))

print("Yes" if H <= A else "No")
//  [python]
a,b = map(int,input().split())
c = sum(map(int,input().split()))
print("Yes" if a<=c else "No")
//  [python]
H, N = map(int, input().split())
A_list = map(int, input().split())
print("Yes" if sum(A_list) >= H else "No   ")
//  [python]
import numpy as np

ene=list(map(int, input().split()))
num=list(map(int, input().split()))

if ene[0]>np.array(num).sum():
    print("No")
else:
    print("Yes")
//  [python]
h, n = input().split()
h = int(h)
n = int(n)
attack = sorted(list(map(int, input().split())), reverse=True)
while  n > 0:
    m_attack = attack[0]
    if h - m_attack <= 0:
        h = h - m_attack
        print("Yes")
        break
    else:   
        h = h - m_attack
        attack.remove(m_attack)
        n = n-1
if h > 0:
    print("No")
//  [python]
H, N = map(int, input().split())
List = list(map(int, input().split()))
List.sort()
List.reverse()
#print(List)

i=0
while i<N:
    H-=List[0]
    del List[0]
    i+=1
    
if H<=0:
    print("Yes")
else:
    print("No")
//  [java]
import java.util.*;

public class Main {
    public static void main(String[] args){
        Scanner scan = new Scanner( System.in );

        int health = Integer.parseInt(scan.next()); 
        int varN   = Integer.parseInt(scan.next());
        ArrayList<Integer> attack = new ArrayList<Integer>();
        for(int i=0; i<varN; i++){
            attack.add( Integer.parseInt( scan.next() ) );
        }

        boolean flag = false;

        for(int i=0; i<varN; i++){
            health -= attack.remove(0);

            if(health <= 0){
                flag = true;
                break;
            }
        }

        if(flag){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        }

    }
}
//  [java]
import java.util.Scanner;
public class Main {
	public static void main(String[]args) {
		Scanner s = new Scanner(System.in);
		double h = s.nextDouble();
		double n = s.nextDouble();
		double m =0;
		for(int i = 0;i<n;i++) {
			m += s.nextDouble();
		}
		if(m>=h) {
			System.out.print("Yes");
		}else {
			System.out.print("No");
		}
		
	}
}
//  [java]
import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		int monster_h = sc.nextInt();
		int skill_n = sc.nextInt();

		List<Integer> skill_list = new ArrayList<>();

		for (int i = 0; i < skill_n; i++) {
			skill_list.add(sc.nextInt());
		}

		int total_skill = skill_list.stream().mapToInt(Integer::intValue).sum();
		String yesNo = (total_skill >= monster_h) ? "Yes" : "No";

		System.out.println(yesNo);
		sc.close();
	}
}
//  [cpp]
#pragma GCC optimize ("O3")
#pragma GCC target ("avx")
//#include<bits/stdc++.h>
#include<cstdio>
using namespace std;
typedef long long ll;
#define rep(i, n) for(int i = 0; i < (n); i++)
#define rep1(i, n) for(int i = 1; i <= (n); i++)
#define co(x) cout << (x) << "\n"
#define cosp(x) cout << (x) << " "
#define ce(x) cerr << (x) << "\n"
#define cesp(x) cerr << (x) << " "
#define pb push_back
#define mp make_pair
#define chmin(x, y) x = min(x, y)
#define chmax(x, y) x = max(x, y)
#define Would
#define you
#define please

const int cm = 1 << 17;
char cn[cm], * ci = cn + cm, ct;
inline char getcha() {
	if (ci - cn == cm) { fread_unlocked(cn, 1, cm, stdin); ci = cn; }
	return *ci++;
}
inline int getint() {
	int A = 0;
	if (ci - cn + 16 > cm) while ((ct = getcha()) >= '0') A = A * 10 + ct - '0';
	else while ((ct = *ci++) >= '0') A = A * 10 + ct - '0';
	return A;
}

int main() {
	//cin.tie(0);
	//ios::sync_with_stdio(false);


	int H = getint(), N = getint();
	int goukei = 0;
	rep(i, N) goukei += getint();
	if (goukei >= H) printf("Yes");
	else printf("No");

	Would you please return 0;
}
//  [cpp]
#pragma GCC optimize ("O3")
#pragma GCC target ("avx")

#include <cstdio>
#include <cstdint>
#include <unistd.h>

using i64 = std::uint_fast32_t;

struct fio {
private:
  constexpr static int is = 1 << 17;
  char ib[is], *ip = ib + is;
public:
  inline fio& operator>>(char& c) {
    if (ip == ib + is) { read(STDIN_FILENO, ib, is); ip = ib; }
    c = *ip++;
    return *this;
  }
  inline fio& operator>>(i64& r) {
    char it;
    r = 0;
    if (ip + 16 > ib + is) while ((*this >> it, it & 16)) r = r * 10 + it - '0';
    else while ((it = *ip++) & 16) r = r * 10 + it - '0';
    return *this;
  }
};

fio fio;

namespace io {
  constexpr int is = 1 << 17;
  char ib[is], *ip = ib + is, it;
  inline char getc() {
    if (ip == ib + is) { read(STDIN_FILENO, ib, is); ip = ib; }
    return *ip++;
  }
  inline i64 scan() {
    i64 r = 0;
    if (ip + 16 > ib + is) while ((it = getc()) & 16) r = r * 10 + it - '0';
    else while ((it = *ip++) & 16) r = r * 10 + it - '0';
    return r;
  }
  constexpr int os = 1 << 17;
  char ob[os], *op = ob, ot;
  inline void putc(const char c) {
    *op++ = c;
    if (op == ob + os) { write(STDOUT_FILENO, ob, os); op = ob; }
  }
  /* x shoud be greater than or equal to zero */
  inline void print(i64 x) {
    char d[20];
    int i = 0;
    while (true) {
      d[i] = x % 10 + 48;
      x /= 10;
      ++i;
      if (x <= 0) break;
    }
    while (i--) {
      putc(d[i]);
    }
  }
  inline void flush() {
    write(STDOUT_FILENO, ob, op - ob);
  }
}

signed main() {
  i64 h, n;
  fio >> h >> n;
  i64 s = 0;
  for (int i = 0; i < n; i++) {
    i64 a;
    fio >> a;
    s += a;
  }
  if (s >= h) {
    puts("Yes");
  } else {
    puts("No");
  }
  return 0;
}
//  [cpp]
#pragma GCC optimize ("O3")
#pragma GCC target ("avx")

#include <cstdio>
#include <cstdint>
#include <unistd.h>

using i64 = std::uint_fast32_t;

namespace io {
  constexpr int is = 1 << 17;
  char ib[is], *ip = ib + is, it;
  inline char getc() {
    if (ip == ib + is) { read(STDIN_FILENO, ib, is); ip = ib; }
    return *ip++;
  }
  inline i64 scan() {
    i64 r = 0;
    if (ip + 16 > ib + is) while ((it = getc()) & 16) r = r * 10 + it - '0';
    else while ((it = *ip++) & 16) r = r * 10 + it - '0';
    return r;
  }
  constexpr int os = 1 << 17;
  char ob[os], *op = ob, ot;
  inline void putc(const char c) {
    *op++ = c;
    if (op == ob + os) { write(STDOUT_FILENO, ob, os); op = ob; }
  }
  /* x shoud be greater than or equal to zero */
  inline void print(i64 x) {
    char d[20];
    int i = 0;
    while (true) {
      d[i] = x % 10 + 48;
      x /= 10;
      ++i;
      if (x <= 0) break;
    }
    while (i--) {
      putc(d[i]);
    }
  }
  inline void flush() {
    write(STDOUT_FILENO, ob, op - ob);
  }
}

signed main() {
  using namespace io;
  i64 h = scan();
  i64 n = scan();
  i64 s = 0;
  for (int i = 0; i < n; i++) {
    s += scan();
  }
  if (s >= h) {
    puts("Yes");
  } else {
    puts("No");
  }
  return 0;
}
//  [cpp]
#define _GLIBCXX_DEBUG
#include <iostream>
#include <cstdio>
#include <cstring>
#include <vector>
#include <deque>
#include <queue>
#include <array>
#include <set>
#include <map>
#include <cmath>
#include <algorithm>
#include <numeric>
#include <utility>
#include <tuple>
#include <functional>
#include <bitset>
#include <cstdint>
#include <cassert>
#include <random>
using namespace std;

int		main(void)
{
	int		H, N;
	cin >> H >> N;
	vector<int> A(N);
	for (int i = 0; i < N; i++)
		cin >> A.at(i);
	sort(A.begin(), A.end(), greater<int>());
	for (auto &i : A)
	{
		H -= i;
		if (H <= 0)
		{
			cout << "Yes" << endl;
			return 0;
		}
	}
	cout << "No" << endl;
}
//  [cpp]
#include<iostream>
#include<vector>
#include<algorithm>
using namespace std;

/*
H N
A1 A2 … AN

*/
bool Rackoon_fight(vector<int>& damage, int& H)
{
   sort(damage.begin(),damage.end());
   for(int i=0; i<damage.size();i++) 
   {
   		H-=damage[i];
   		if(H<=0) return true;
   }
   return false;
   
}

int main()
{
   int H, N,d;
   vector<int> damage(N);
   cin>> H >> N;
   for(int i=0; i<N;i++) 
   {
   	cin>>d;
   	damage.push_back(d);
   }
   
   if(Rackoon_fight(damage,H))
	cout<< "Yes"<<endl;
   else
	cout<< "No" <<endl;
  return 0;

}
//  [cpp]
#include <iostream>
#include <vector>
#include <string>
#include <sstream>
#include <numeric>


template <typename DataType>
auto convert(const std::string& data_str) -> DataType {
	std::stringstream ss;
	DataType ret {};

	ss << data_str;
	ss >> ret;

	return ret;
}




auto input() {
	int H, N;
	std::cin >> H >> N;
	return std::make_pair(H,N);
}


auto split(const std::string& str) {
	std::vector<std::string> ret {};

	std::size_t currentp {}, nextp {};
	while(true) {
		nextp = str.find_first_of(' ', currentp);

		ret.push_back(str.substr(currentp, nextp-currentp));
		
		if(nextp == std::string::npos)
			break;
		
		currentp = nextp + 1;
	}

	return ret;
}


auto extract(const std::string& str) {
	std::vector<int> skill_set {};

	for(auto&& s : split(str))
		skill_set.push_back(convert<int>(s));

	return skill_set;
}


auto judge(int H, const std::vector<int>& skill_set) {
	return std::accumulate(skill_set.begin(), skill_set.end(), 0) >= H;
}


void process() {
	auto data = input();

	std::string s;
	std::getline(std::cin, s);
	std::getline(std::cin, s);

	auto skill_set = extract(s);

	std::cout << (judge(data.first, skill_set) ? "Yes" : "No") << std::endl;
}

int main() {
	process();
}
//  [c]
char buf[1<<20];sz;
N,H;
main()
{
	read(0,buf,1<<20);
	for(;;)
	{
		char k=buf[sz++];
		if(k<'0')break;
		H=H*10+k-'0';
	}
	for(;;)
	{
		char k=buf[sz++];
		if(k<'0')break;
		N=N*10+k-'0';
	}
	for(int i=0;i<N;i++)
	{
		int A=0;
		for(;;)
		{
			char k=buf[sz++];
			if(k<'0')break;
			A=A*10+k-'0';
		}
		H-=A;
	}
	puts(H>0?"No":"Yes");
}
//  [c]
// ABC 153-B
// 2020.1.26 bal4u

#include <stdio.h>

#define gc() getchar_unlocked()

int in() {   // 非負整数の入力
	int n = 0, c = gc();
	do n = 10 * n + (c & 0xf); while ((c = gc()) >= '0');
	return n;
}

int main()
{
	int H, N;
	
	H = in(), N = in();
	while (N--) H -= in();
	puts(H <= 0? "Yes": "No");
	return 0;
}
//  [c]
#include<stdio.h>
#include<stdlib.h>
#include<string.h>

int main(void) {
	int H;
	int N;
	int sum = 0;
	int i;
	char buf[128], *ch;
	char *buf_array;

	fgets(buf, sizeof(buf), stdin);
	ch = strtok(buf, " ");
	H = atoi(ch);
	ch = strtok(NULL, " ");
	N = atoi(ch);

	buf_array = (char *)calloc(N * 8, sizeof(char));

	fgets(buf_array, N * 8, stdin);
	ch = strtok(buf_array, " ");
	sum += atoi(ch);
	for(i = 1; i < N; i += 1) {
		ch = strtok(NULL, " ");
		sum += atoi(ch);
	}

	if(H <= sum) {
		printf("Yes\n");
	} else {
		printf("No\n");
	}

	free(buf_array);
	return 0;
}
//  [c]
#include<stdio.h>

int main(void){
   int H,N;
   scanf("%d %d",&H,&N);
   int a[N];
   for(int i=0;i<N;i++){
      scanf("%d",&a[i]);
      H -=a[i];
   }
   if(H<=0){
      printf("Yes");
   }else{
      printf("No");
   }
   return 0;
}
//  [c]
#include<stdio.h>
int main() {
   int h, n;
   int a = 0;
	scanf("%d %d", &h, &n);
	int x[n];
   
	for(int i = 0; i < n; i++) {
		scanf("%d", &x[i]);
		a = a+x[i];
	}
   
	if(a >= h) {
		printf("Yes");
	}
	else {
      printf("No");
   }
   printf("\n");
	return 0;
}
//  [c]
#include <stdio.h>
typedef long long ll;

int main(void) {
    ll H, N;
    scanf("%lld%lld", &H, &N);

    ll ASum = 0;
    for(ll i = 0; i < N; ++i) {
        ll tmp;
        scanf("%lld", &tmp);
        ASum += tmp;
    }
    
    if(ASum >= H) {
        printf("Yes\n");
    } else {
        printf("No\n");
    }

    return 0;
}
//  [javascript]
function main(input) {
    var line = input.split(/\r?\n/g);
    var arr = line[0].split(" ");
    const H = arr[0], N = arr[1];
    var A = line[1].split(" ");
    var accum = 0;
    for (var i = 0; i < A.length; i++)
        accum += parseInt(A[i]);
    console.log(1 < Math.ceil(H / accum) ? "No" : "Yes");
}
main(require('fs').readFileSync('/dev/stdin', 'utf8'));
//  [javascript]
function main(input) {
    var line = input.split(/\r?\n/g);
    var arr = line[0].split(" ");
    const H = arr[0], N = arr[1];
    var A = line[1].split(" ");
    var accum = 0;
    for (var i = 0; i < A.length; i++)
        accum += parseInt(A[i]);
    console.log(accum < H ? "No" : "Yes");
}
main(require('fs').readFileSync('/dev/stdin', 'utf8'));
//  [javascript]
var nodes = [];
var restrictions = [];
function Main(input) {
    // 1行目がinput[0], 2行目がinput[1], …に入る
    input = input.split("\n");
    var tmp = input[0].split(" ");
    var hp = tmp[0];

    var waza = input[1].split(" ");
    var total = 0;
    for (var i = 0; i < waza.length; i++) {
        total += parseInt(waza[i]);
    }
    if (total >= hp) {
        console.log("Yes");
    } else {
        console.log("No");

    }

}

//*この行以降は編集しないでください（標準入出力から一度に読み込み、Mainを呼び出します）
Main(require("fs").readFileSync("/dev/stdin", "utf8"));
//  [javascript]
"use strict";
var GET=(function(){function f(s){return new g(s);}function g(s){this._s=s.trim().split("\n");this._y=0;}g.prototype.a=function(f){var s=this._s, y=this._y, r;if(typeof s[y]==="string")s[y]=s[y].split(" ").reverse();r=s[y].pop();if(!s[y].length)this._y++;return f?r:+r;};g.prototype.l=function(f){var s=this._s[this._y++].split(" ");return f?s:s.map(a=>+a);};g.prototype.m=function(n,f){var r=this._s.slice(this._y,this._y+=n).map(a=>a.split(" "));return f?r:r.map(a=>a.map(a=>+a));};g.prototype.r=function(n,f){var r=this._s.slice(this._y,this._y+=n);return f?r:r.map(a=>+a);};return f;})();
var o=GET(require("fs").readFileSync("/dev/stdin","utf8"));
function xArray(v){var a=arguments,l=a.length,r="Array(a["+--l+"]).fill(0).map(x=>{return "+v+";})";while(--l)r="Array(a["+l+"]).fill(0).map(x=>"+r+")";return eval(r);}

var myOut = main();
if(myOut !== undefined)console.log(myOut);
function main(){
  var h = o.a();
  var n = o.a();
  var a = o.l();
  return h<=a.reduce((a,b)=>a+b)?"Yes":"No";
}
//  [javascript]
"use strict"
const create = () => {
    const input = require("fs").readFileSync("/dev/stdin", "utf8").trim().split("\n");
    const res = {
        "list": input, "index": 0, "max": input.length,
        "hasNext": function() {return this.index < this.max},
        "next": function() { if (!this.hasNext()) {throw "ArrayIndexOutOfBoundsException";}else{return this.list[this.index++];}}
    };
    return res;
}
const o = create();
const next = () => o.next()
const nextInt = () => parseInt(o.next())
const nextStrArray = () => o.next().split(" ")
const nextIntArray = () => o.next().split(" ").map(el => parseInt(el))
const nextCharArray = () => o.next().split("")
const hasNext = () => o.hasNext()
const myout = (...x) => console.log(...x)
const Main = () => {
    let [h,n] = nextIntArray()
    const a = nextIntArray()
    for(let i=0; i<a.length; i++){
        h -= a[i]
    }
    console.log( h<=0 ? "Yes" : "No")

}
Main()
//  [javascript]
'use strict';
const main = input => {
  const nums = input[0].split(' ').map(val => parseInt(val));
  const h = nums[0], n = nums[1];
  let a = input[1].split(' ').map(val => parseInt(val));
  const sum = a.reduce((prev, current) => prev + current);
  console.log(h<=sum?'Yes':'No');
}
main(require("fs").readFileSync("/dev/stdin", "utf8").split('\n'));
//  [go]
package main

import (
	"bufio"
	"fmt"
	"os"
	"strconv"
	"strings"
)

const (
	initialBufSize = 10000
	maxBufSize     = 1000000
)

var sc *bufio.Scanner = func() *bufio.Scanner {
	sc := bufio.NewScanner(os.Stdin)
	buf := make([]byte, initialBufSize)
	sc.Buffer(buf, maxBufSize)
	return sc
}()

func main() {
	var sum int
	i := scanIntNums()
	i2 := scanIntNums()

	H := i[0]
	for _, num := range i2 {
		sum += num
	}

	if sum >= H {
		fmt.Println("Yes")
	} else {
		fmt.Println("No")
	}

}

func scanIntNums() (nums []int) {
	sc.Scan()
	numString := strings.Split(sc.Text(), " ")

	nums = make([]int, len(numString))
	var err error

	for i := 0; i < len(nums); i++ {
		nums[i], err = strconv.Atoi(numString[i])
		if err != nil {
			panic(err)
		}
	}
	return nums
}
//  [go]
package main

import "fmt"

func main() {
	var H int
	var skillNum int
	var skill int
	fmt.Scan(&H)
	fmt.Scan(&skillNum)

	for i := 0; i < skillNum; i++ {
		fmt.Scan(&skill)
		H = H - skill
	}
	if H > 0 {
		fmt.Print("No")
	} else {
		fmt.Print("Yes")
	}
}
//  [go]
package main

import (
	"fmt"
)

func main() {
	var H int
	var N int
	var buf int
	sm := 0

	fmt.Scan(&H)
	fmt.Scan(&N)
	for i := 0; i < N; i++ {
		fmt.Scan(&buf)
		sm += buf
	}
	if sm >= H {
		fmt.Println("Yes")
	} else {
		fmt.Println("No")
	}
}
//  [go]
package main

import "fmt"

func main() {
	var h, n int
	fmt.Scan(&h, &n)
	a := make([]int, n)
	sum :=0
	for i:=0; i<n; i++{
		fmt.Scan(&a[i])
		sum += a[i]
	}

	if sum >= h{
		fmt.Println("Yes")
	}else{
		fmt.Println("No")
	}
}
//  [ruby]
input = gets.split
hp = input[0].to_i

attacks = gets.split
attacks.each do |attack|
  hp = hp - attack.to_i
end

if hp <= 0
  puts "Yes"
else
  puts "No"
end
//  [ruby]
get = gets.split(' ')

h = get[0].to_i
n = get[1].to_i
a = gets.split(' ')

a.each do |a|
  h = h - a.to_i
end
if h > 0
  puts "No"
else
  puts "Yes"
end
//  [ruby]
h, n = gets.chomp.split(' ').map{|i| i.to_i }
sum = 0
gets.chomp.split(' ').map{|i| sum += i.to_i }
if sum >= h
  puts 'Yes'
else
  puts 'No'
end
//  [ruby]
H, N = gets.split.map(&:to_i)
a = gets.split.map(&:to_i)
for i in 0..N-1 do
  H -= a[i]
end
if H <= 0
  puts "Yes"
else
  puts "No"
end
//  [ruby]
H, N = gets.chomp.split.map(&:to_i)
A = gets.chomp.split.map(&:to_i)
A.each do |attack|
  H = H - attack
end
puts H > 0 ? 'No' : 'Yes'
//  [ruby]
h,n = gets.split.map(&:to_i)  # スペースで区切られた複数の整数
ary = gets.split.map(&:to_i)  # スペースで区切られた複数の整数

newary = ary.sort {|a, b| (-1) * (a <=> b) }  # 配列降順ソート

i = 0
ans = h
while i < n do
  ans = ans - newary[i]
  i = i + 1
end

if ans <= 0 then
  puts "Yes"
else
  puts "No"
end
//  [rust]
use text_io::*;
use std::collections::*;
use std::process::exit;

fn main() {
    let mut h:usize = read!();
    let mut n:usize = read!();
    let mut v:usize = 0;
    for i in 0..n {
        let a:usize = read!();
        v += a;
    }
    if h<=v {
        println!("Yes");
        exit(0);
    }
    println!("No");
}
//  [rust]
use std::io::*;
use std::str::FromStr;

fn read<T: FromStr>() -> T {
    let stdin = stdin();
    let stdin = stdin.lock();
    let token: String = stdin
        .bytes()
        .map(|c| c.expect("filed to read char") as char)
        .skip_while(|c| c.is_whitespace())
        .take_while(|c| !c.is_whitespace())
        .collect();
    token.parse().ok().expect("failed to parse token")
}

fn main() {
    let mut h:i64 = read();
    let n:usize = read();
    let mut v:Vec<i64> = (0..n).map(|_| read()).collect();
    v.sort();
    for _ in 0..n {
        h -= v.pop().unwrap();
    }
    if h <= 0 {
        println!("Yes");
    } else {
        println!("No");
    }
}
//  [swift]
let input = readLine()!.split(separator: " ").map { Int($0)! }
let H = input[0]
let N = input[1]
let A = readLine()!.split(separator: " ").map { Int($0)! }

print(A.reduce(0, +) >= H ? "Yes" : "No")
//  [swift]
let arr = readLine()!.characters.split{$0==" "}.map{Int(String($0))}
let h = arr[0]
let n = arr[1]

let a = readLine()!.characters.split{$0==" "}.map{Int(String($0))}
var sumA = 0
a.forEach{sumA += $0!}

print((h <= sumA) ? "Yes" : "No")
//  [typescript]
import * as fs from 'fs';
 
const lines = fs.readFileSync('/dev/stdin', 'utf8').split("\n");
let [h,n] = lines[0].split(" ").map(Number);
let a = lines[1].split(" ").map(Number);

let s = 0;
for(let i = 0; i < n; i++){
    s += a[i];
}

if (s>=h){
    console.log("Yes");
}
else{
    console.log("No");
}
//  [typescript]
import * as fs from "fs";

const input = (fs.readFileSync("/dev/stdin", "utf8") as string).split("\n");
//const n = +input[0];
//const a = [];
//for(let i=0;i<n;i++){
//	a.push(input[i+1].split(" ").map((x:string):number=>+x));
//}

//const [n, m] = input[0].split(" ").map((x: string): number => +x);
//const a = input[1].split(" ").map((x: string): number => +x);


const [h, n] = input[0].split(" ").map((x: string): number => +x);
const a = input[1].split(" ").map((x: string): number => +x);

let tmp = 0;

for (let i = 0; i <n; i++){
    tmp += a[i];
}

if (tmp >= h){
    console.log('Yes');
}else{
    console.log('No');
}
//  [typescript]
import * as fs from 'fs'

const input = fs.readFileSync('/dev/stdin', 'utf8').split('\n');
const line1 = input[0];
const line2 = input[1];
let h = parseInt(line1.split(' ')[0], 10);
const n = parseInt(line1.split(' ')[1], 10);

const tech = line2.split(' ').map(n => parseInt(n, 10));
for (let i = 0; i < tech.length; i++) {
    h -= tech[i];
}

if (h <= 0) {
    console.log('Yes');
} else {
    console.log('No');
}

// 210 5
// 31 41 59 26 53
// console.log(h);
// console.log(n);
// console.log(line2);
// console.log(tech);
//  [typescript]
import * as fs from 'fs';
 
const lines = fs.readFileSync('/dev/stdin', 'utf8').split("\n");
let [h,n] = lines[0].split(" ").map(Number);
let a = lines[1].split(" ").map(Number);

let s = a.reduce((b,c) => b + c);

if (s>=h){
    console.log("Yes");
}
else{
    console.log("No");
}
//  [typescript]
class AtCoder {
  // 入力系
  input=[];
  input_i=-1;
  n(){
    this.input_i++;
    return Number(this.input[this.input_i]);
  }
  nn(n){
    const a=[];
    for(let i=0;i<n;i++){
      a.push(this.n());
    }
    return a;
  }
  s(){
    this.input_i++;
    return String(this.input[this.input_i]);
  }
  ss(n){
    const a=[];
    for(let i=0;i<n;i++){
      a.push(this.s());
    }
    return a;
  }

  // コンソール
  o(...a:any){
    console.log(...a);
  }

  // Math
  abs(a:number){
    return Math.abs(a);
  }
  min(...a:number[]){
    return Math.min(...a);
  }
  max(...a:number[]){
    return Math.max(...a);
  }
  floor(a:number){
    return Math.floor(a);
  }
  ceil(a:number){
    return Math.ceil(a);
  }
  round(a:number){
    return Math.round(a);
  }

  // ソート
  asc(ar:number[]){
    const t=[...ar];
    ar.sort((a,b)=>{return a-b});
  }
  desc(ar:number[]){
    const t=[...ar];
    ar.sort((a,b)=>{return b-a});
  }

  // 自作
  gcd(...arr):number{
    for(let i=0;i<arr.length-1;i++){
      let [x,y]=[arr[i],arr[i+1]];
      while(y){
        [x,y]=[y,x%y];
      }
      arr[i+1]=x;
    }
    return arr[arr.length-1];
  };
  lcm(...arr):number{
    for(let i=0;i<arr.length-1;i++){
      let [x,y]=[arr[i],arr[i+1]];
      while(y){
        [x,y]=[y,x%y];
      }
      arr[i+1]=arr[i]*arr[i+1]/x;
    }
    return arr[arr.length-1];
  };
  isPrime(n:number):boolean{
    if(n < 2) return false;
    const suq=Math.sqrt(n);
    for(let i=2;i<=suq;i++){
      if(n%i==0){
        return false;
      }
    }return true;
  };
  deduplicate(a:any[]):any[]{
    return Array.from(new Set(a));
  };
}
const o = new AtCoder()
var reader = require('readline').createInterface({
  input: process.stdin,
  output: process.stdout
});
reader.on('line',(line)=> {
  o.input.push(...line.split(/[\s]/));
});

process.stdin.on('end', ()=> {
  let [n,m]=o.nn(2),sum=0
  for(let i=0;i<m;i++)sum+=o.n()
  o.o(sum>=n?'Yes':'No')
});