6 Apr 2015
Encrypt
Encrypt key:
a=e, b=f, c=g, d=h, e=i, f=j, g=k, h=l, i=m, j=n, k=o, l=p, m=q,
n=r, o=s, p=t, q=u, r=v, s=w, t=x, u=y, v=z, w=a, x=b, y=c, and z=d.
Decrypt key:
a=w, b=x, c=y, d=z, e=a, f=b, g=c, h=d, i=e, j=f, k=g, l=h, m=i, n=j, o=k, p=l, q=m, r=n, s=o, t=p, u=q, v=r, w=s, x=t, y=u, and z=v
Using this technique a user could encrypt the message . Below is an example of how this could be done using Perl.my (%key, $new); my $alpha = "abcdefghijklmnopqrstuvwxyz"; my $message = "computer hope free help for everyone"; @alpha = split(//, $alpha); my $i=1; foreach $alpha (@alpha) { if ($i >= 23) { $i = -3; } $key{$alpha} = $alpha[$i+3]; $i++; } @message = split(//,$message); foreach $message (@message) { if ($message =~/[a-z]/i) { $new .= "$key{$message}"; } else { $new .= "$message"; } } print "Old: $message\nEncrypted: $new\n";
Conversion Tool
A version of the above code is also available online to encrypt and convert your own text.
Related Posts
Subscribe to:
Post Comments
(
Atom
)
No comments :
Post a Comment