Duration is the PV-weighted average time to each cash flow.
Duration formula
Macaulay duration is the PV-weighted average period where each discounted payment is weighted by its period and normalized by price.
DMac=∑PV(Ct)∑t⋅PV(Ct)=121331 periods
Exact vs rounded duration
For this par bond, the exact value is 331/121 periods, about 2.7355 periods at four-decimal display.
331/121≈2.7355