阅读背景:

为什么updateStocks()没有改变价格?

来源:互联网 

I have a method to read a text file of five stocks using Scanner and delimiter. I also have a method which should take a double multiplier and an array of stock objects and change the price with that multiplier. The method which reads the stock file functions correctly, however, when I attempt to change the stock objects that have been assigned values with the filereading method, it does not change the price. After I use method updateStocks(), I test stock[1] to see if the value has changed and it has not.I have a method to read a text file of five sto




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: