Hi,
I am not computer savvy at all. i am a math major so I am utterly lost
I need to read information form a text file i created called Item
this is the file
where
item, ID, stock, price respectively
pretzel,0,20,25
chips,1,20,50
mints,2,20,75
gum,3,20,100
chocolate,4,20, 125
cookies,5,20,15 0
trail mix,6,20,175
pop tarts,7,20,200
I am creating a class that access this file and then displays and allows me to manipulate the data
public class VendorClass
{
private String [] [] itemList;
public VendingItems(St ring [] [] itemList);
this is all i have so far. Our teachr assigned us this project but has not gotten this far in the course. the book we have also does not have examples of how to read double array from a text file, otherwise I would have used that
Also, I need to know how to selectively change the stock and price into integers not Strings
any help would be appreciatted. i am going out of my mind
I am not computer savvy at all. i am a math major so I am utterly lost
I need to read information form a text file i created called Item
this is the file
where
item, ID, stock, price respectively
pretzel,0,20,25
chips,1,20,50
mints,2,20,75
gum,3,20,100
chocolate,4,20, 125
cookies,5,20,15 0
trail mix,6,20,175
pop tarts,7,20,200
I am creating a class that access this file and then displays and allows me to manipulate the data
public class VendorClass
{
private String [] [] itemList;
public VendingItems(St ring [] [] itemList);
this is all i have so far. Our teachr assigned us this project but has not gotten this far in the course. the book we have also does not have examples of how to read double array from a text file, otherwise I would have used that
Also, I need to know how to selectively change the stock and price into integers not Strings
any help would be appreciatted. i am going out of my mind
Comment