LCD printing problem

Hello,

I use Arduino MEGA 2560 and LCD 16x2. I am trying to print this:

char NUMBER[10] = "1111122222";

with this function:

void test()
{
    lcd.clear();
    lcd.setCursor(0, 0);
    lcd.print("Current number:");
    lcd.setCursor(0, 1);
    lcd.print(NUMBER);
    delay(1000);
}

but I get strange characters...

When I print only the first line (0), the Current number: is printed ok, but when I try to print both lines, it prints strange characters. I also tried using the BASE, using DEC, but then it didn't compile... What I do wrong??

Update: It also prints me this warning: warning: initializer-string for array of chars is too long [-fpermissive]

Thank you...

char NUMBER[10] = "1111122222";

That string is too big to fit in a 10 element array. Yes it has 10 characters but you need another one for the string terminator.

You are much better doing

char NUMBER[] = "1111122222";

Yes, thank you, everything ok now!!