.title len ; ; call len( string ) ; returns length of null terminated string ; .psect user$i len:: tst (r5)+ ; discard nargs mov (r5),r0 ; address of string 10$: tstb (r0)+ ; null ?? bne 10$ ; br, if no dec r0 ; point to last chr, NOT null sub (r5),r0 ; calculate length return .end