<CsoundSynthesizer>
<CsInstruments>
sr = 44100
kr = 4410
ksmps = 10
nchnls = 1
0dbfs = 1.0

instr 1
    tabw_i -1.0, 3, 1
endin

instr 2
    iread_value tab_i 3, 1
    prints "%f\n", iread_value
endin

instr 3
    ifn = p4
    isize = ftlen(ifn)    
    prints "Index\tValue\n"
    
    iindex = 0
    begin_loop:
        ivalue tab_i iindex, ifn
        prints "%d:\t%f\n", iindex, ivalue
        iindex = iindex + 1
    if (iindex < isize) igoto begin_loop
    
    turnoff
endin


</CsInstruments>
<CsScore>
f 1 0 16 10 1  ; Create a 16 point sine wave

i 3 0 1 1      ; Print the contents of the table
s
i 2 0 1        ; Print the value at index 3
s
i 1 0 1        ; Change value at index 3 to -1
i 3 0 1 1      ; Print the contents of the table
</CsScore>
</CsoundSynthesizer>

