Doubt

You create an application for employees to submit timesheets. Employees enter work, vacation, and sick time for a particular week. On the entry form, employees see a summary of the total hours entered. After the employee submits the timesheet, the application displays remaining vacation and sick time for the employee. To configure the form where users enter hours, select the best configuration option to calculate the total hours for the week.

A. Use a data transform. When the user enters the form, the data transform determines the sum of the work, vacation, and sick tune properties.

B. Use declarative processing. When the value of any work, vacation, or sick time changes, the total hours change.

C. Use procedural processing. When the value of any work, vacation, or sick time changes and the user submits the form, the total hours change.

D. Use a When route. When the value of any work, vacation, or sick time changes, the total hours change.

The answer for this in many sites says C but i think it should be B as whenever the entered hours changes, the total hours changes(forward chaining). Can anyone please confirm the answer.

The correct answer is B (Use declarative processing). In this case, the total hours need to update automatically whenever the employee changes work, vacation, or sick time on the form. Declarative processing in Pega supports this through forward chaining, meaning the total recalculates instantly when any dependent value changes, without waiting for form submission. Option C is not correct because it relies on procedural logic that triggers only after submission, which does not meet the requirement of real-time updates on the entry screen. This scenario is exactly what declarative rules are designed for, ensuring the UI always reflects the latest calculated total.