Initial data commit
This commit is contained in:
parent
72d218235f
commit
f23f22d71c
199087 changed files with 3378941 additions and 0 deletions
27
Task/MD5/Delphi/md5.delphi
Normal file
27
Task/MD5/Delphi/md5.delphi
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
program MD5Hash;
|
||||
|
||||
{$APPTYPE CONSOLE}
|
||||
|
||||
uses
|
||||
SysUtils,
|
||||
IdHashMessageDigest;
|
||||
|
||||
function MD5(aValue: string): string;
|
||||
begin
|
||||
with TIdHashMessageDigest5.Create do
|
||||
begin
|
||||
Result:= HashStringAsHex(aValue);
|
||||
Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
begin
|
||||
Writeln(MD5(''));
|
||||
Writeln(MD5('a'));
|
||||
Writeln(MD5('abc'));
|
||||
Writeln(MD5('message digest'));
|
||||
Writeln(MD5('abcdefghijklmnopqrstuvwxyz'));
|
||||
Writeln(MD5('ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789'));
|
||||
Writeln(MD5('12345678901234567890123456789012345678901234567890123456789012345678901234567890'));
|
||||
Readln;
|
||||
end.
|
||||
Loading…
Add table
Add a link
Reference in a new issue