How can I approach the inverse for currency prices and have them stored in an array?
For example: EURUSD = 1.1050 means USD/EUR = .9049
on a simple calculator we simply take 1/1.1050 which doesn't seem to work so well in arrays
Lets say
P1 = 1/iClose(NULL,0,n+1);
Buffer1 = P1;
with the code above I get a zero divide problem,
however if I just use 1/iClose(NULL,0,1); instead without the adding to the array value, it computes the proper calculation.
how can I get these to work for stored values?
For example: EURUSD = 1.1050 means USD/EUR = .9049
on a simple calculator we simply take 1/1.1050 which doesn't seem to work so well in arrays
Lets say
P1 = 1/iClose(NULL,0,n+1);
Buffer1 = P1;
with the code above I get a zero divide problem,
however if I just use 1/iClose(NULL,0,1); instead without the adding to the array value, it computes the proper calculation.
how can I get these to work for stored values?