vladittude0583
- 40
- 0
Our homework requires us to write a program that will calculate the total resistance of a circuit with "infinite" resistor values.
My question is, how would I calculate the "infinite" portion of the code? I already know that this will require a while loop with some if/for statements. I am just unsure of how to write the code that take will care of the "infinite" number of values of resistors.
If you could give me an idea as to how to do so it would be greatly appreciated - on a side note, I am in C+ programming and not C++ programming, so please provide me with an answer in terms of the language I am familiar too and not one above it. Thanks.
My question is, how would I calculate the "infinite" portion of the code? I already know that this will require a while loop with some if/for statements. I am just unsure of how to write the code that take will care of the "infinite" number of values of resistors.
If you could give me an idea as to how to do so it would be greatly appreciated - on a side note, I am in C+ programming and not C++ programming, so please provide me with an answer in terms of the language I am familiar too and not one above it. Thanks.