It's hard to discern anything from the code snippet you've provided. Could you point us to the actual problem that's causing you grief? I'd like to import it into a dummy course and then test it to see what might be happening. While you're at it, could you make sure the source is available?
Rex Abert Associate Professor of Mathematics Tallahassee Community College ________________________________________ From: lon-capa-users-boun...@mail.lon-capa.org [lon-capa-users-boun...@mail.lon-capa.org] on behalf of Bob Gonzales [rgon...@binghamton.edu] Sent: Friday, May 29, 2015 8:44 AM To: Discussion list for LON-CAPA users Subject: [LON-CAPA-users] Illegal division by zero Hi, I've gotten a couple of email bombs on a problem where the error is "Illegal division by zero". The text of the message is: Illegal division by zero at (eval 53074) line 5. occurred while running $t2=&random(1,3); $sub2=&choose($t2,"carbon","hydrogen","oxygen"); $f2=&choose($t2,20.0,24.0,2.0); $ansb=($ansa/$f1)* $f2 * 6.0221e23; The "Script Vars" in the message shows "$f1=6.0221e+23". The actual code defines $f1 as "6.0221e23" via a &choose function. This has happened for 3 students on 3 different access servers. Does anyone have any ideas about what's going on or what I'm doing wrong here? Thanks, Bob Gonzales Chemistry Dept Binghamton University _______________________________________________ LON-CAPA-users mailing list LON-CAPA-users@mail.lon-capa.org http://mail.lon-capa.org/mailman/listinfo/lon-capa-users