import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;
public class Main {
public static void main(String[] args) throws IOException {
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
StringTokenizer st = new StringTokenizer(br.readLine());
int a1 = Integer.parseInt(st.nextToken());
int a0 = Integer.parseInt(st.nextToken());
int c = Integer.parseInt(br.readLine());
int n0 = Integer.parseInt(br.readLine());
if ((a1 * n0 + a0) <= c * n0 && a1 <= c) {
System.out.println(1);
} else {
System.out.println(0);
}
br.close();
}
}
'코딩 테스트 > JAVA - 백준 단계별로 풀어보기' 카테고리의 다른 글
[백준 Java] 브루트 포스 - 2231번: 분해합 (0) | 2025.02.20 |
---|---|
[백준 Java] 브루트 포스 - 2798번: 블랙잭 (1) | 2025.02.19 |
[백준 Java] 시간 복잡도 - 24267번: 알고리즘 수업 - 알고리즘의 수행 시간 6 (1) | 2025.02.18 |
[백준 Java] 시간 복잡도 - 24266번: 알고리즘 수업 - 알고리즘의 수행 시간 5 (0) | 2025.02.18 |
[백준 Java] 시간 복잡도 - 24265번: 알고리즘 수업 - 알고리즘의 수행 시간 4 (0) | 2025.02.18 |