Re: [GD-General] not sure where to post this question... bit C++ implementation specific....
Brought to you by:
vexxed72
From: Jorrit T. <jor...@uz...> - 2004-07-07 08:17:07
|
Richard Fabian wrote: >its a bit C++ specific, but does anyone know of a way of getting the >"meaning" of this to compile... > >const float ropeLength = 12.5f; >const float knotSpace = 3.3f; >int array[ ropeLength / knotSpace ]; > >... its sorta meaning we have to break our own coding guidlines.... (no >#defines unless truly necessary) > > > Well using #define is one way. The only other way is using allocation: int* array = new int[ropeLength / knotSpace]; But then you must remember to delete[] it later. Greetings, |