結果
問題 |
No.442 和と積
|
ユーザー |
![]() |
提出日時 | 2016-11-12 19:08:02 |
言語 | Java (openjdk 23) |
結果 |
RE
|
実行時間 | - |
コード長 | 281 bytes |
コンパイル時間 | 1,833 ms |
コンパイル使用メモリ | 74,476 KB |
実行使用メモリ | 41,520 KB |
最終ジャッジ日時 | 2024-11-25 21:23:47 |
合計ジャッジ時間 | 5,044 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 RE * 1 |
other | AC * 1 WA * 3 RE * 14 |
ソースコード
import java.util.Scanner; public class Main { public static long gcd(long n,long r){ return r==0?n:gcd(r,n%r); } public static void main(String[] args) { Scanner sc=new Scanner(System.in); long a=sc.nextInt(); long b=sc.nextInt(); System.out.println(gcd(a,b)); } }