View Single Post
  #2 (permalink)  
Old 10-12-2006, 09:09 AM
Lop's Avatar   
Lop Lop is offline
Speaks fluent binary
 
Join Date: May 2006
Posts: 1,149
Credits: 0
Rep Power: 18
Lop will become famous soon enoughLop will become famous soon enough
Default

Are you using ANSI C++?

For the arrays you can use the split function to create them which will make the size dynamic. Split by linebreak. Lets call this guy array1[].

Next cycle through the data using a for loop. Add array[0] to another array, lets call him dataArray[array[0]][array.Length-1]

Code:
// Using .NET code, convert to whatever - this is just for logic
for (int i=1;i<array.Length;i++) {
dataArray[array[0]][i] = array[i];
}
For the names only create another array and use a function to determine if the value of array[i] is a integer. If not, copy to the function.
__________________
Lop
Reply With Quote