Algorithms Sequential & Parallel: A Unified Approach