if ( index >= 0 && index < = 9999 )


if (index >=0)

else if

else

....................