Semirings and Affine Equations over Them