PersonalCorpus 版 (精华区)

152825 08:54:29 3 Mar 2002
Bozhang,HIT,P.R.China 1191 Pascal Accepted 0.02 sec 49K


var
    l,n,k:integer;
begin
    readln(l,n);
    while n>0 do begin
        dec(n);
        read(k);
        if l<k then begin writeln('YES');halt end;
        l:=l-(l mod k);
    end;
    if l=0 then writeln('YES') else writeln('NO');
end.
[百宝箱] [返回首页] [上级目录] [根目录] [返回顶部] [刷新] [返回]
Powered by KBS BBS 2.0 (http://dev.kcn.cn)
页面执行时间:2.774毫秒