also fixed bug in subtract