QOJ.ac

QOJ

Límite de tiempo: 2 s Límite de memoria: 1024 MB

#23957. Blackjack

Estadísticas

問題文

3 つの整数 A, B, C が与えられる.

3 つの値の合計が 21 以下なら 1 を,そうでないなら 0 を出力せよ.

制約

  • 1 ≦ A ≦ 13.
  • 1 ≦ B ≦ 13.
  • 1 ≦ C ≦ 13.
  • 入力される値はすべて整数である.

入力

入力は以下の形式で与えられる.
A
B
C

出力

3 つの値の合計が 21 以下なら 1 を,そうでないなら 0 を出力せよ.

答え以外は何も出力しないこと.(入力を促す文章なども出力しないこと.)

解答形式については,練習問題やその解答例 を参考にしても良い.


入力例 1

5
10
6

出力例 1

1
  • 3 つの値の合計は,5 + 10 + 6 = 21 であり,21以下である.よって 1 を出力する.

入力例 2

7
8
13

出力例 2

0
  • 3 つの値の合計は,7 + 8 + 13 = 28 であり,21以下ではない.よって 0 を出力する.

Discussions

About Discussions

The discussion section is only for posting: General Discussions (problem-solving strategies, alternative approaches), and Off-topic conversations.

This is NOT for reporting issues! If you want to report bugs or errors, please use the Issues section below.

Open Discussions 0
No discussions in this category.

Issues

About Issues

If you find any issues with the problem (statement, scoring, time/memory limits, test cases, etc.), you may submit an issue here. A problem moderator will review your issue.

Guidelines:

  1. This is not a place to publish discussions, editorials, or requests to debug your code. Issues are only visible to you and problem moderators.
  2. Do not submit duplicated issues.
  3. Issues must be filed in English or Chinese only.
Active Issues 0
No issues in this category.
Closed/Resolved Issues 0
No issues in this category.