Seeing as the last thread was started a good 3/4 yr previous, thought it couldn't hurt to post another. Either everyone has left the LispForum-Quiz-of-the-delta-T and I'm talking to myself, or people out there are waiting for #2. I read a little up on the Ruby quiz -- comes originally from the Perl-quiz-of-the-week, which had this in its charter:
Since the last one was a bit tough, this one should be easy. Plot the mandelbrot set. Define a function (mb rmin rmax imin imax) taking 4 real numbers, that will print-print-plot a 30 row, 50 column image of the mandelbrot setThe 'regular' quiz can be solved using only techniques and functions found in Learning Perl (3rd edition) by Schwartz and Phoenix. The 'expert' quiz may be difficult. The two kinds of quizzes appear on alternate weeks.
For example,
Code: Select all
#;> (mb -2.0 1.0 -1.5 1.5)
..................................................
..................................................
....................::::::::::....................
..............::::::::::::::::::::::..............
...........::::::::::::::::://$//::::::...........
........:::::::::::::::::::////$%/::::::::........
.......::::::::::::::::::////$$#$///:::::::.......
.....:::::::::::::::::://////####$/////::::::.....
....::::::::::::::::///$%/$$$$##%$$$////::::::....
...:::::::::::::///////$############$##%/::::::...
..:::::::::://///////$%%##############$///::::::..
.::::::::///$///$////%%#################$/:::::::.
.:::::://////$#%%#%$$%##################//:::::::.
.::::://////$#######%##################%//:::::::.
.////////$%#%#########################%///:::::::.
.////////$%#%#########################%///:::::::.
.::::://////$#######%##################%//:::::::.
.:::::://////$#%%#%$$%##################//:::::::.
.::::::::///$///$////%%#################$/:::::::.
..:::::::::://///////$%%##############$///::::::..
...:::::::::::::///////$############$##%/::::::...
....::::::::::::::::///$%/$$$$##%$$$////::::::....
.....:::::::::::::::::://////####$/////::::::.....
.......::::::::::::::::::////$$#$///:::::::.......
........:::::::::::::::::::////$%/::::::::........
...........::::::::::::::::://$//::::::...........
..............::::::::::::::::::::::..............
....................::::::::::....................
..................................................
..................................................
Extra credit / golf ides:
* Navigation features for zooming and panning
* Other fractal favorites - Koch snowlflake, xkcd valentines fractal, etc.
* Better ascii art generation (such as using characters that correspond to the image contours)
Have fun.