提出 #74825


ソースコード 拡げる

import std.stdio;
void main(){
	int[] buf;
	readcsi(buf);
	int a,b,c,d,e,f,g;
	a=buf[0];
	b=buf[1];
	c=buf[2];
	readcsi(buf);
	e=buf[0];
	d=buf[1];
	f=buf[2];
	
	writeln( max([
	(a/e) * (b/d) * (c/f),
	(a/e) * (b/f) * (c/d),
	(a/d) * (b/e) * (c/f),
	(a/d) * (b/f) * (c/e),
	(a/f) * (b/d) * (c/e),
	(a/f) * (b/e) * (c/d)
	]) );
}


import std.conv,std.string;
void readcsi(T)( ref T[] arr ){
	arr = [];
	
	
	string[] str = split(chomp(readln()));
	foreach( s ; str ){
		arr ~= to!T(s);
	}
	return;
}

T max(T)( T[] t ){
	T max = T.min;
	foreach( i ; t ){
		if( max < i ){
			max = i;
		}
	}
	return max;
}

提出情報

提出日時
問題 A - 梱包できるかな?
ユーザ hotcocoamix
言語 D (DMD 2.060)
得点 100
コード長 648 Byte
結果 AC
実行時間 19 ms
メモリ 824 KiB

ジャッジ結果

セット名 All
得点 / 配点 100 / 100
結果
AC × 35
セット名 テストケース
All 00_sample_01.txt, 00_sample_02.txt, 00_sample_03.txt, 00_sample_04.txt, 01_rand_00.txt, 01_rand_01.txt, 01_rand_02.txt, 01_rand_03.txt, 01_rand_04.txt, 01_rand_05.txt, 01_rand_06.txt, 01_rand_07.txt, 01_rand_08.txt, 01_rand_09.txt, 01_rand_10.txt, 01_rand_11.txt, 01_rand_12.txt, 01_rand_13.txt, 01_rand_14.txt, 01_rand_15.txt, 01_rand_16.txt, 01_rand_17.txt, 01_rand_18.txt, 01_rand_19.txt, 01_rand_20.txt, 01_rand_21.txt, 01_rand_22.txt, 01_rand_23.txt, 01_rand_24.txt, 01_rand_25.txt, 01_rand_26.txt, 01_rand_27.txt, 01_rand_28.txt, 01_rand_29.txt, 99_min.txt
ケース名 結果 実行時間 メモリ
00_sample_01.txt AC 18 ms 788 KiB
00_sample_02.txt AC 19 ms 788 KiB
00_sample_03.txt AC 19 ms 788 KiB
00_sample_04.txt AC 19 ms 792 KiB
01_rand_00.txt AC 19 ms 788 KiB
01_rand_01.txt AC 19 ms 704 KiB
01_rand_02.txt AC 19 ms 684 KiB
01_rand_03.txt AC 18 ms 792 KiB
01_rand_04.txt AC 19 ms 792 KiB
01_rand_05.txt AC 18 ms 788 KiB
01_rand_06.txt AC 18 ms 784 KiB
01_rand_07.txt AC 19 ms 796 KiB
01_rand_08.txt AC 19 ms 784 KiB
01_rand_09.txt AC 19 ms 784 KiB
01_rand_10.txt AC 19 ms 788 KiB
01_rand_11.txt AC 19 ms 768 KiB
01_rand_12.txt AC 19 ms 788 KiB
01_rand_13.txt AC 18 ms 788 KiB
01_rand_14.txt AC 18 ms 764 KiB
01_rand_15.txt AC 19 ms 796 KiB
01_rand_16.txt AC 18 ms 792 KiB
01_rand_17.txt AC 19 ms 700 KiB
01_rand_18.txt AC 19 ms 784 KiB
01_rand_19.txt AC 19 ms 688 KiB
01_rand_20.txt AC 19 ms 816 KiB
01_rand_21.txt AC 19 ms 788 KiB
01_rand_22.txt AC 19 ms 792 KiB
01_rand_23.txt AC 19 ms 796 KiB
01_rand_24.txt AC 18 ms 792 KiB
01_rand_25.txt AC 19 ms 788 KiB
01_rand_26.txt AC 19 ms 788 KiB
01_rand_27.txt AC 18 ms 788 KiB
01_rand_28.txt AC 19 ms 696 KiB
01_rand_29.txt AC 19 ms 824 KiB
99_min.txt AC 19 ms 788 KiB