I for some reason can have a variable sized array. For example main.cpp (it's an attachment) can compile & run perfectly! Can someone tell me why it works and how it doesn't say it works on all the tutorials.
I have not looked through the attachment, but my first guess is that you are using the variable length array extension ported to g++ from gcc's implementation of C99. As such, it is not part of standard C++.
C + C++ Compiler: MinGW port of GCC
Build + Version Control System: SCons + Bazaar
* The Best Reasons to Target Windows 8
Learn some of the best reasons why you should seriously consider bringing your Android mobile development expertise to bear on the Windows 8 platform.