@groth said in What's So Hard About Ruby?:
MUSHcode serves as a fairly good introduction to Lisp. Dialects of Lisp and languages similar to Lisp are still used by systems that need concurrency like telecom and financial backends.
That's true, but Lisp languages are such an infinitesimally small percentage of real-world programming that it's kind of like learning some weird dialect language that's only spoken in a far-flung corner of the world. Sure, if you live there or have a specific application for it, it's useful. But in general? Not so much.
Lisp-based languages have different design patterns. Lots of recursion and nested function calls umpteen layers deep. MUSHCode in particular lacks many features of most modern languages - classes, named variables, clear function definitions (to @Tat's point about understanding helper functions) or even comments and whitespace (unless you use a custom offline parser). And the way people generally code in MUSHCode is very different - no source control, editing live on game, putting in your code all smushed together onto a single line. These are things that would be considered unacceptable in almost any other programming venue.
I'm not saying Lisp (or MUSHCode for that matter) is a bad language. They have their niche uses.
But come on... this is ONE function from the FS3 combat system in MUSHCode. Even with liberal FUN_ helpers, t's insane. It's just not a good way to learn how to program. And I say that as someone who has literally taught programming.
&FUN_ACTION_ATTACK FS3Combat Instance Parent=localize([setq(0,u(fun_combatstat,%0,ammo))][setq(1,switch(grab(%2,burst,,),,1,min(%q0,3)))][setq(2,u(fun_weaponstat,%0,recoil))][setq(3,u(fun_range_mod,%0,after(grab(%2,range=,,),=)))][switch(0,t(u(fun_combatstat,%0,weapon)),u(fun_combat_msg,[prettify(lcstr(%0))] tries to attack but has no weapon!),t(u(fun_combatstat,%0,target)),u(fun_combat_msg,[prettify(lcstr(%0))] tries to attack but has no target!),not(u(fun_out_of_ammo,%0)),u(fun_combat_msg,[prettify(lcstr(%0))] tries to attack but is [ansi(hr,out of ammo)]!),[switch(%q1,>1,u(fun_combat_msg,[prettify(lcstr(%0))] fires a [ansi(hm,%q1 round burst)]!))][iter(lnum(1,%q1),[u(fun_do_attack,%0,switch(u(fun_is_in_vehicle,%1),1,u(fun_combatstat,%1,vehicle),%1),unprettify(after(grab(%2,called=,,),=)),add(%q3,-[mul(sub(#@,1),%q2)]),0)])][u(fun_suppress,%1,switch(u(fun_weaponstat,%0,wpntype),melee,0,1))][u(fun_subtract_ammo,%0,%q1)][switch(u(fun_out_of_ammo,%0),1,u(fun_combat_msg,ansi(hm,[prettify(lcstr(%0))]'s weapon clicks empty.)))])])