結果

問題 No.1113 二つの整数 / Two Integers
ユーザー m0ch1m0ch1m0ch1m0ch1
提出日時 2020-09-29 15:15:49
言語 Go
(1.22.1)
結果
TLE  
実行時間 -
コード長 389 bytes
コンパイル時間 9,940 ms
コンパイル使用メモリ 199,736 KB
実行使用メモリ 4,376 KB
最終ジャッジ日時 2023-09-17 00:18:45
合計ジャッジ時間 13,647 ms
ジャッジサーバーID
(参考情報)
judge11 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 1 ms
4,376 KB
testcase_01 AC 2 ms
4,376 KB
testcase_02 TLE -
testcase_03 -- -
testcase_04 -- -
testcase_05 -- -
testcase_06 -- -
testcase_07 -- -
testcase_08 -- -
testcase_09 -- -
testcase_10 -- -
testcase_11 -- -
testcase_12 -- -
testcase_13 -- -
testcase_14 -- -
testcase_15 -- -
testcase_16 -- -
権限があれば一括ダウンロードができます

ソースコード

diff #

package main

import "fmt"

func min(a ...int) int {
	m := a[0]
	for i, v := range a {
		if i == 0 {
			continue
		}
		if m > v {
			m = v
		}
	}
	return m
}
func main() {
	var A, B int
	fmt.Scan(&A, &B)

	c := min(A, B)
	var count int = 1
	for i := 2; i <= c; i++ {
		if A%i == 0 && B%i == 0 {
			count++
		}
	}
	if count%2 == 0 {
		fmt.Println("Even")
	} else {
		fmt.Println("Odd")
	}
}
0