Sunday, 15 September 2013

Declaring arrays similar to C style (C++) -


A programmer in C can declare an array like this:

  unsigned Four fonts [2] [8] {[1] = {0, 31, 0, 31, 0, 31, 0, 31}};  

and element [0] is likely to have random bits. Is there any such way in C ++?

You can:

  unsigned char fonts [2 ] [8] = {{0}, {0, 31, 0, 31, 0, 31, 0, 31}};  

No comments:

Post a Comment