A comparison screen can make the largest payment look like the obvious choice. The actual transport-tool source instead accepts revenue, costs and several kinds of time separately.
This story goes beyond the earlier separation-of-formula article to examine the comparison denominator. The new independent example uses small fixed synthetic values rather than actual driver income or current market rates.
Read payment and time separately
The source distinguishes loaded and empty distance, economy and fuel price, tolls and confirmed fees. It also separates driving, waiting, handling or paperwork, and planned rest. A simple comparison result therefore depends on several different observations and assumptions. Before turning revenue into a score for a good trip, I want those meanings to be inspectable.
A confirmed cost and an allocated budget are different inputs. Removing rest to make a plan look faster would also misrepresent its basis. This example adds all declared planned time; it does not decide whether a route is safe or legally permitted. Operational conditions requiring separate review stay outside the comparison contract.
Include empty travel and waiting on the same basis
Unloaded travel still consumes fuel, so total distance includes loaded and empty portions. The new plan function calculates fuel from that distance and declared economy and price. Waiting and handling may produce no additional revenue, but they still belong in total planned time. Excluding them from one option would undermine a claim of comparable conditions.
The code does not query actual roads or tolls and cannot verify where an input came from. It produces consistent results for numbers declared by a trusted caller. With unknown omitted costs, I call the result a residual within the stated calculation boundary rather than a confirmed net profit.
Use a small reversal example
Synthetic plan A has revenue twelve hundred, cost one hundred and two hundred forty minutes. B has revenue one thousand, cost one hundred and one hundred twenty minutes. A retains more total value, eleven hundred, while its hourly value is two hundred seventy-five compared with B’s four hundred fifty. Those are demonstration values, not market prices.
Local tests check both rankings. Displayed hourly values are rounded integers, but the winner is chosen by exact fractions so display rounding cannot manufacture a tie. The reader should be able to explain why the rankings differ. The model does not automatically accept a real dispatch or choose an operational route.
An unknown schedule has no known buffer
The source returns a null schedule when arrival and cutoff are absent, yet its difference calculation can substitute zero for a missing buffer. The new independent example leaves the difference unknown whenever either schedule is absent. That is a code observation and a new contract, not an invented record of a customer incident.
Paired times use one declared civil-calendar basis. Tests cover midnight, a negative buffer, a nonexistent date and a missing half of the pair. There is no timezone conversion or live arrival forecast. The boundary distinguishes a known comparison from an unknown one; a screen cannot recover uncertainty after an upstream layer has already changed it into zero.
Define what the comparison action promises
Tests cover lower revenue with higher hourly residual, extra waiting and rest, empty-distance fuel, missing schedules and unchanged input objects. The independent package includes no company dispatch sheet or contact information. Its viewer reads the actual saved local execution records rather than running a transport service.
For another business, first decide which resource belongs in the denominator. An hour, a distance and a completed job answer different questions. Explain input provenance and omitted costs before reviewing the integrated interface. I share a way for visitors to inspect the reason for a comparison instead of relying on a visually prominent number.