You can of course include much more info, for example any additional arguments you need to pass to the program. You could also make the strings non-constant and load all the programs from an easily formatted file, like XML for instance.

You can of course include much more info, for example any additional arguments you need to pass to the program. You could also make the strings non-constant and load all the programs from an easily formatted file, like XML for instance.

Hey man,

That looks amazing, thing is, im new to coding and not even sure if thats C? Havent seen it before, im trying to keep to code thats familiar/basic!

Line #13 (declaration inside the for statement) is C99, although all compilers support it as an extension regardless. You should be using C99 anyway, all compilers support it (if yours doesn't, don't use TurboC!).

I can't make it any more basic than that... Ok, I could use two arrays instead of the struct, but I think that would make things more complicated. You need to keep associated data together to avoid confusion. If that "sizeof" bit confuses you, it just takes advantage of the fact that the compiler knows both the size of the whole array (because it's static) and the size of individual elements of the array.