Rename member variable "n" to "len"

Describes the _length_ of the array, not the number of elements.
Rename member variable "next" to "num"

Describes the number of elements of the object.
Fix variable name for command number in processor code
Fix variable names in tests
Merge pull request #329 from matthiasbeyer/fix-variable_names_transaction

Fix variable names in transaction type