In my thinking, as a programmer, debit = positive, and credit = negative. NOW, what type of account those are going to like others have said changes things, but fundamentally if you are adding a positive amount to an account thats a debit, and if you are adding a negative amount thats a credit.
I don't understand what you mean well enough. So you might be right or you might be wrong :)
Can you share a couple of example (or maybe use the same examples I did)?