Quote Originally Posted by CuriousOne View Post
Picbasic has no idea about negative numbers, anything goes below 0 gets deducted from 65535.
Re-read the single line I sent. I was not talking about PBP. I'm talking about representation of integers in a binary system. Read this article: https://www.cs.cornell.edu/~tomf/not.../twoscomp.html What most software developers do when they want to know when the variable goes "below zero", is look at the most significant bit. If it is high, the number is negative, if it is low, the number is positive. Since you are using a word, then your largest positive number will be 32768.