How do I use a multidimensional array to read data from an input file (1 3 4). where the first each element represents different variable types to be manipulated?
How do I use a multidimensional array to read data from an input file (1 3 4). where the first each element represents different variable types to be manipulated?
I think you want an array of "structures".
StructureArray[1].char1
StructureArray[1].int1
StructureArray[1].float1
What happends if you have two seperate files and want an array for each text file. Would you declare two structures or just one?
I have two text files. One contains names and the other phone numbers. How would I go about of having "number_array" containg all the numbers in the numbers.txt and have "name_array" contain all the names in names.txt??
Are you working on the client only or is this a client/server? In other words, does the program read and write the data or does it read only? If this is the first case, one solution is to design the data in a structure or a class and write in binary mode. As you read them back, one solution is to store them in a container.
Kuphryn
kuphryn:
thanks for the reply and this is for the client side. i'll be reading a list of names and phone numbers to create a database using a hash table. i'm not too familar about writing in binary mode but i'll do a search.
pelp