結果

問題 No.3005 天使のハッシュ関数
ユーザー Ysmr_RyYsmr_Ry
提出日時 2014-12-30 13:34:34
言語 C++11
(gcc 11.4.0)
結果
AC  
実行時間 11 ms / 5,000 ms
コード長 368 bytes
コンパイル時間 805 ms
コンパイル使用メモリ 53,492 KB
実行使用メモリ 4,380 KB
最終ジャッジ日時 2023-09-03 20:17:38
合計ジャッジ時間 1,423 ms
ジャッジサーバーID
(参考情報)
judge12 / judge13
外部呼び出し有り
このコードへのチャレンジ
(要ログイン)

テストケース

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

ソースコード

diff #

#include<cstdio>
#include<cstdlib>
#include<iostream>
#include<string>

std::string md5( const std::string &s )
{
	std::string cmd = "echo -n "+s+"| md5sum";
	FILE *fp = popen( cmd.c_str(), "r" );

	char buf[50];
	fscanf( fp, "%s", buf );
	fclose(fp);

	return buf;
}

int main()
{
	std::string s;
	std::cin >> s;

	std::cout << md5(md5(s)) << std::endl;

	return 0;
}
0