prog8/examples/test.p8

47 lines
886 B
Plaintext
Raw Normal View History

2020-03-24 23:32:54 +00:00
%import c64lib
%import c64utils
%import c64flt
%zeropage basicsafe
2020-07-26 22:32:59 +00:00
main {
2020-07-26 21:32:20 +00:00
sub start() {
2020-08-18 13:16:56 +00:00
2020-08-23 16:32:53 +00:00
ubyte[] arr1=[11,22,33]
uword[] array=[1111 ,2222,3333]
2020-08-23 16:20:57 +00:00
float[] farr = [1.111, 2.222, 3.333]
2020-08-23 16:32:53 +00:00
2020-08-23 20:36:49 +00:00
ubyte ub
uword uw
float ff
2020-08-23 16:32:53 +00:00
ubyte i = 1
2020-08-23 20:36:49 +00:00
arr1[i] = ub
array[i] = uw
farr[2] = 3.15
farr[2] = ff
farr[i] = ff
c64flt.print_f(farr[1])
2020-08-23 16:32:53 +00:00
c64.CHROUT('\n')
; c64scr.print_ub(arr1[1])
; c64.CHROUT('\n')
; arr1 [i] ++
; c64scr.print_ub(arr1[1])
; c64.CHROUT('\n')
;
; c64scr.print_uw(array[1])
; c64.CHROUT('\n')
; array[i] ++
; c64scr.print_uw(array[1])
; c64.CHROUT('\n')
;
; c64flt.print_f(farr[1])
; c64.CHROUT('\n')
; farr[i] ++
; c64flt.print_f(farr[1])
; c64.CHROUT('\n')
2020-07-25 23:32:27 +00:00
}
}