This question evaluates proficiency in expression parsing, operator precedence handling, integer arithmetic semantics (including truncating division), and efficient tokenization and evaluation within the Coding & Algorithms domain.

Implement a function to evaluate a string expression containing non-negative integers, '+', '-', '*', '/', and spaces. Multiplication and division have higher precedence than addition and subtraction, and division truncates toward zero. Parentheses are not allowed. Do not use any built-in eval. Handle long inputs efficiently and document time and space complexity.