initializer element is not constant...
Hi
I'm trying to compile the following code, but gcc 4.2 returns the messages
"global.c:8: error: initializer element is not constant"
"global.c:9: error: initializer element is not constant"
Code:
#include <stdio.h>
#include <math.h>
#include <stdlib.h>
/*file global.c*/
static long double h=1e-2;
static long double t_max=2.0*3.1415926535897932384626433832795;
static long double y_max=100.0;
static unsigned int lin=(int)(y_max/h+2);
static unsigned int col=(int)(t_max/h+1);
int main()
{
return 0;
}
Can anyone help me? Nothing that I read on the subject is much clear about this... :(