Pure Programmer
Blue Matrix


Cluster Map

Project: Random Characters

Write a program to generate a random stream of Unicode characters. The program should accept three values on the command line: minimum character codepoint, maximum character codepoint and the number of characters to generate. Be sure not to output control characters in the specified range. Include assertions to check that the command line min and max are in the range 0-0x1ffff.

Output
$ perl RandomChars.pl 0 255 100 "rand" is not exported by the Math::Trig module Can't continue after import errors at RandomChars.pl line 10. BEGIN failed--compilation aborted at RandomChars.pl line 10. $ perl RandomChars.pl 940 969 100 "rand" is not exported by the Math::Trig module Can't continue after import errors at RandomChars.pl line 10. BEGIN failed--compilation aborted at RandomChars.pl line 10.

Solution