Welcome to Phrogram Sign in | Join | Help
in Search


Browse by Tags

All Tags » Assert
  • Re: Divide by zero

    Thanks for your prompt reply Jamey. Assert looks interesting but wouldn’t the program stop running? I want the program just to ignore it not carry out that line and carry on. Doing some tests I found the following. Define k as decimal k=100/0 Will produce a divide by zero error Define k as decimal k=0 k=100/k This does not produce an ...
    Posted to KPL Questions and Answers (Forum) by DaveG27 on January 29, 2007
  • Re: Divide by zero

    You probably want to use Assert, something like this:            Assert ( x <> 0, "Whoa! You're trying to divide by 0." )    
    Posted to KPL Questions and Answers (Forum) by Jamey on January 29, 2007