CodeNewbie Community 🌱

Discussion on: Arrays in C Programming

Collapse
 
michaelcurrin profile image
Michael Currin • Edited on

Shorthand array definition.

#include <stdio.h>

void main() {
  int arr[] = {5, -10, 2, 6};

  printf("%d %d %d %d", arr[0], arr[1], arr[2], arr[3]);
}
Enter fullscreen mode Exit fullscreen mode

Also note use of syntax highlighting by specifying language.

```c
Content 
```
Enter fullscreen mode Exit fullscreen mode