Basic icon indicating copy to clipboard operation
Basic copied to clipboard

NUL char cannot be part of a string?

Open gdelconti opened this issue 6 years ago • 2 comments

See example below:

print "ESP Basic 3.0.Alpha 69"

' let define some control character let NUL = chr(0) 'required let SOH = chr(1) 'can be any let STX = chr(2) 'can be any

print "correct with any combitation of control char but the NUL" let s = SOH & STX print asc(left(s,1)) print asc(right(s,1))

print "wrong if NUL is part of the string" let s = NUL & STX print asc(left(s,1)) print asc(right(s,1))

gdelconti avatar Nov 04 '18 10:11 gdelconti