Regularization enters as a penalty term added to the squared-error objective. In the one-weight setup, that changes the normal equation without leaving exact arithmetic.
highlighted = computed this step
The ridge penalty
Ridge adds λ*w squared to the squared-error objective. In the through-origin one-weight model, that adds λ to the denominator.
squared error+λw2
Modified normal equation
The exact normal equation becomes w times (sum x squared plus λ) equals sum xy. Solving gives w(λ)=sum xy divided by (sum x squared plus λ).
w(∑x2+λ)=∑xy,w(λ)=∑x2+λ∑xy
Summary
Regularization has not introduced a non-exact step. The displayed λ is a chosen exact value, and the weight is still a Fraction.