Small question I have going through the tutorial. RRS feed

  • Question

  • So, I'm a n00b to programming. Heard about SmallBasic... found the tutorial pdf that Vijaye wrote... been following along smoothly.

    Just one question:
    what does prevX or prev anything do?

    i don't think he explained it. does it just find the previous location?

    Sunday, July 19, 2009 9:17 AM


  • Yes! you've understood it correct. It's variable for storing last position. It's useful i.e. if you have to draw line. You compute new line end and draw from last point used to new position. Then you store your new end as prevX and prevY and you can compute new position. It's common trick in programming.
    • Marked as answer by Lukeman Sunday, July 19, 2009 12:23 PM
    Sunday, July 19, 2009 10:53 AM