https://www.cnblogs.com/yeungchie/
- code
procedure(Decrypt(inputFile @optional outputFile(nil))
prog((inp out line)
if(inputFile
then
unless(outputFile
outputFile = sprintf(nil "%s.dec" inputFile)
)
when(isFile(outputFile)
print("You must specify a file thatdoesn't exist!!!
")
hiGetAttention()
return()
)
unless(inp = infile(inputFile)
printf("Unable to open input file:%s
" inputFile)
return()
)
unless(out = outfile(outputFile "w")
printf("Unable to open output file:%s
" outputFile)
return()
)
while(line = lineread(inp)
when(line != t
pprint(line out)
)
)
close(inp)
close(out)
else
printf("You must at least specify aninput file!
")
return()
)
return(t)
)
);Decrypt
- describe
- example