Hello everyone,
for my assignment for school I have to make a HP calculator which works with 4 stacks, and in RPN.
So i allready got the first 3 stacks(normal array, dynamic array and LinkedList) but the 4th stack is the so called "Crazy stack" here you can make a stack in what ever way you like. So i figured a stack making a folder for every value that i push. And that works awesome. But now the problem everytime I want to pop a value i need to get the folder name of the folder in a folder. for example C:\HP Calc\0\ value (the 0 indicated on which place the value is pushed.) So what i want to know is how i can get the name of the value inside the folder 0, since i dont know what the value's folder name is.
Thanks a lot,
Dave
Loading
D BPosted Mar 16, 2009, 2:45 AM
Jan MontanoPosted Mar 15, 2009, 11:20 PM
static void Test1()
{
string sourceDirectory = @"C:\HP Calc\0\";
//string sourceDirectory = @"C:\Documents and Settings";
string[] subdirectories = Directory.GetDirectories(sourceDirectory);
for (int i=0; i
Console.WriteLine(subdirectories[i]);
}
}
D BPosted Mar 15, 2009, 6:52 AM