Some Functional Equations in Groups and Rings.