I am quite stuck in an operation where I have to calculate a sum using circular reference.
Though in Excel , it's quite easy (or already managed by excel itself) to use circular reference but I am not sure how to implement this thing in C#.
The problem is like this:
I have to sum a whole range of cells and then two values in cells use the sum itself for their own calculation.that is,
if i have sum = num1 + num2 + num3 + num4,
then num2 = someVariable + sum/someVariable2;
and similarly num4 also uses sum in its value.
To start with I guess I should take sum = 0 and then calculate num2 and num4, that will give me a new sum that further can give me new value for two variables and finally I can get final sum.
But I am quite confused whether this approach is correct or not.