Hardy Huang a écrit :
> Hi,
>     Suppose I want to have a List of an int array. How should I code it 
> using STL?
>   

Hi, something like this :
#include <list>
using std::list;

const int n = 10; // assuming 10 is your favorite value
int main() {
    list< int[n] > myList;
}

May be an list of vector may help you.
Regards,
David

> I typed list<int> myList[n] in Visual Studio 2005. n variable must be 
> entered using a keyboard manually.
> I got an error which is "expected constant expression".
> Can someone help me please?
>
> Regards,
> Hardy Huang
>
>   



To unsubscribe, send a blank message to <mailto:[EMAIL PROTECTED]>. 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/c-prog/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to