An engineering programmer records completion times for three tasks using two alternative workflows. Both workflows finish with code that meets the same stated requirements. Each workflow runs sequentially, and the recorded phases do not overlap. Prompting time includes waiting for the AI response; revision time includes all subsequent corrections and rechecks.
Task
Manual completion (min)
Prompt and generate (min)
Review (min)
Revise (min)
Calculation
30
4
18
12
Import
75
8
28
14
Report
120
70
48
Define net time saving as manual completion time minus total AI-assisted completion time. Complete the table with exact integer minutes. A negative saving means that the AI-assisted workflow takes longer.
Unlock full course notes by signing up
Quantifying a generated result's error
A heater has four power readings of 100100100, 200200200, 300300300, and 400 W400\ \text{W}400 W at times 000, 333, 666, and 9 s9\ \text{s}9 s. The required energy estimate uses trapezoidal integration:
where energy is in kilojoules. An AI-generated function instead returns
Choosing a test that separates implementations
Two AI-generated functions estimate energy from three equally spaced power readings. One uses sample-mean power multiplied by the record duration:
The other implements the required trapezoidal model:
Does a fitted correction generalize?
An AI-generated energy function accepts n≥2n\geq2n≥2 finite, nonnegative power readings in watts and a finite positive spacing Δt\Delta tΔt in seconds. It returns
in kilojoules. The required model is
Checking an AI proposal against a memory budget
An AI assistant proposes a numerical program that retains a full N×NN\times NN×N distance matrix for N=10 000N=10\,000N=10000 three-dimensional points. Every matrix entry occupies 8 bytes. The program has a strict total budget of 512 MiB, and all memory outside the distance matrix occupies exactly 128 MiB under the supplied planning model. Use 1 MiB=1 048 576 bytes1\ \text{MiB}=1\,048\,576\ \text{bytes}1 MiB=1048576 bytes.
You request a revised implementation that processes rrr rows at a time without retaining the full matrix. In this revised plan, the fixed allocation is still 128 MiB. In addition, each block requires these three arrays:
Coordinate differences: r×N×3r\times N\times3r×N×3 entries, each occupying 8 bytes.