I'm facing k&r exercise 1.24, that states: "Write a program to check a C program for rudimentary syntax errors like unmatched parentheses, brackets and braces".
I'm not sure about how to deal with square brackets.
Are nested square brackets possible in ANSI C syntax ? I haven't yet seen them so far, but I'm only at Chapter 1.
Sure it is possible, access an array, in the place denoted in a second array. a[b[i]]
It is often used for bucket sort, where your buckets is a second array, and each bucket is an element in this array.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With