1 条题解
-
0
C++ :
#include<bits/stdc++.h> using namespace std; int main(){ int c,s,a1,a2,a3; cin>>c>>s>>a1>>a2>>a3; c=a1+a2+a3; if(c<=20)cout<<"YES"<<endl; else cout<<"NO"<<endl; return 0; }
Pascal :
var a,b,c,d,e,g:longint; f:real; begin read(a,b,c,d,e); f:=a/b+c+d+e; if f<=20 then write('YES') else write('NO'); end.
Java :
import java.util.Scanner; public class Main{ public static void main(String[] arjs) { Scanner sc =new Scanner(System.in); int n =sc.nextInt(); int a =sc.nextInt(); int b =sc.nextInt(); int c =sc.nextInt(); int e =sc.nextInt(); int k =n*a; if(k>a*e+(b+c)) { System.out.println("YES"); }else { System.out.println("NO"); } } }
- 1
信息
- ID
- 1230
- 时间
- 1000ms
- 内存
- 16MiB
- 难度
- (无)
- 标签
- 递交数
- 0
- 已通过
- 0
- 上传者