Computer Music: Musc216
Cocoa Sample Code


for next loops:

for ( i = 0; i < myNumber; i++) {

[do something spiffy here];

}


for (int i = 0; i < nDestinations; ++i) {

[do something spiffy here];

}

This version is from C++ and is not supported in Cocoa unless you set the proper flag in the GetInfo window. Do this:

1. select the file in XCodes, Groups & Files pane
2. choose Get Info from the file menu
3. select the "Build' tab in the Get Info window
4. enter this EXACTLY: -std=c99 [note the little hyphen before std]
5. close the window
5. save everything


 

Main Page