Java实现 洛谷 P1046 陶陶摘苹果
2024-10-09 06:03:16
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int d = 0;
int b[] = new int[10];
for (int i = 0; i <= 9; i++) {
int a = sc.nextInt();
b[i] = a;
}
int c = sc.nextInt();
for(int i = 0 ; i<=9;i++) {
if(b[i]<=c+30) {
d++;
}
}System.out.println(d);
}
}
最新文章
- Sql Server系列:分区表操作
- ORA-04063: view ";SYS.DBA_REGISTRY"; has errors
- 浅谈Android下的Bitmap之大Bitmap加载
- es6 ... 表达
- 学习笔记:调用js文件冲突问题解决方案
- lintcode :Remove Duplicates from Sorted List 删除排序链表中的重复元素
- Python自动化运维之28、Django(二)
- Delphi 在使用exports中的方法 带参数的用法
- VirtualBox虚拟机安装RedHat7.3编译Linux0.01内核
- Swift学习之构造方法
- bzoj2806 [Ctsc2012]Cheat
- c# 多种方法调整屏幕亮度
- springboot使用@data注解,减少不必要代码
- [转]MYSQL 创建存储过程
- JIT(Just in time,即时编译,边运行边编译)、AOT(Ahead Of Time,运行前编译),是两种程序的编译方式
- c指针类型的作用
- ROS教程0 环境配置
- Singer 学习二 使用Singer进行gitlab 2 postgres 数据转换
- MongoDB 比较适用哪些业务场景?
- shiro web 集成