Camerart
Member
Hi,
I'm trying to understand Procedures and Functions (Using Oshonsoft BASIC)
Here is the example for Procedures:
This is written in such a way, using 'silly words' that makes it very difficult to follow. Can someone re-write it using more normal words, so it flows better please?
Cheers, Camerart.
I'm trying to understand Procedures and Functions (Using Oshonsoft BASIC)
Here is the example for Procedures:
Code:
Dim in_only As Byte
Dim inc_me As Byte
Dim add_inc_me_and_in_only As Byte
in_only = 5
inc_me = 10
Call testbyref(in_only, inc_me, add_inc_me_and_in_only)
'after this call
'inc_me = 11
'add_inc_me_and_in_only = 16
End
Proc testbyref(arg1 As Byte, ByRef arg2 As Byte, ByRefOut arg3 As Byte)
arg2 = arg2 + 1
arg3 = arg1 + arg2
End Proc
This is written in such a way, using 'silly words' that makes it very difficult to follow. Can someone re-write it using more normal words, so it flows better please?
Cheers, Camerart.