2

I'm writing a program for my circuit analysis class that calculates the total resistance in parallel resistors given a list of the Ohms of each resistor. My code is as follows:

DelVar ⌊RL
Input "R List: ",⌊RL
0→RT
For(X,1,dim(⌊RL))
RT+(⌊RL(X))→RT
End
RT→Ans
Disp RT

The code looks fine to me. The little square in there is actually a ^-1 in the calculator. But I get a syntax error when I run this code, which for whatever reason points me to the line 0→RT.

Shayes
  • 41
  • 1
  • 4

1 Answers1

2

Figured it out, apparently most models of the TI-84 don't allow more than 1 letter variable names for number vars. Also yes I noticed a couple mistakes with the calculation in my code, and have fixed it:

DelVar ⌊RL
Input "R List: ",⌊RL
0→R
For(X,1,dim(⌊RL))
R+(⌊RL(X))→R
End
Disp R
Shayes
  • 41
  • 1
  • 4