Minor fixes

Added the accidentally removed test file for test12. Also, rem expressions were using mod instead of rem.