Arithmetic Mean#491

Arithmetic Mean (Editorial)

Author: UOI Team

Prepared by: UOI Team

We are given that is the arithmetic mean of and : (c = a + b2)

To find , we rearrange the equation: \beginalign* a + b2 = c

[0.5em] a + b = 2c

[0.5em] b = 2c - a \endalign*

Answer is (b = 2 c - a).

Time complexity: .