Jump to content
IGNORED

So, what about strings?


Recommended Posts

15 minutes ago, JamesD said:

Most MS BASICs don't support INTs was my point. 

Oddly, all the editions on my arsenal do (Atari, CP/M, IBM-PC)… 

 

Was not aware that such type-declaration was stripped from other implementations... The inter-platform variations are much wider than I thought...

Link to comment
Share on other sites

I'm pretty sure a brought up the fact that everything the MC-10 did was floats.
The Atari version may be the only 6502 version that supports INTs, and none of the 68xx versions I'm aware of do.
Try changing the code like this:

0 DEFINT I,M,I0,IH,IL,J,P,X,O,T,Q,L,N,S
1 J=0:R1$="":M=J:I0=J:IH=J:O=1:T=2:Q=-1
44 IH=INT(IW/T):I0=I(IL+IH)

Link to comment
Share on other sites

11 minutes ago, JamesD said:

I'm pretty sure a brought up the fact that everything the MC-10 did was floats.
The Atari version may be the only 6502 version that supports INTs, and none of the 68xx versions I'm aware of do.
Try changing the code like this:

0 DEFINT I,M,I0,IH,IL,J,P,X,O,T,Q,L,N,S
1 J=0:R1$="":M=J:I0=J:IH=J:O=1:T=2:Q=-1
44 IH=INT(IW/T):I0=I(IL+IH)

I would be REALLY surprised if MS-Basic II on Atari is the only 6502 version that supports Integer declaration...

 

...However, I must inform you about its limitations, too... You cannot specify a variable (per my last attempt, as I get an error)... When you DEFINT with an alpha "X", all names beginning with "X" will be handled as 16-bit integers... that is also part of what happens on MS-Basic85-CP/M80... 

Link to comment
Share on other sites

2 minutes ago, Faicuai said:

I would be REALLY surprised if MS-Basic II on Atari is the only 6502 version that supports Integer declaration...

 

Apple II, Commodore VIC20 / C64 / Plus/4 / C128... nope. 
Maybe the ORIC did, since it also has ELSE, where earlier 6502 versions didn't.  The ORIC came out after the Atari version.
Maybe some of the Tompson machines (6809) had int, but I'm not sure.
It was common on a lot of Z80 versions except really cheap machines.
 

 

12 minutes ago, Faicuai said:

...However, I must inform you about its limitations, too... You cannot specify a variable (per my last attempt, as I get an error)... When you DEFINT with an alpha "X", all names beginning with "X" will be handled as 16-bit integers... that is also part of what happens on MS-Basic85-CP/M80... 

That one's new to me.  I don't remember that on the Model I & III.
The loop variable X should be changed to something else then.

Link to comment
Share on other sites

On 8/12/2019 at 9:20 PM, JamesD said:

Maybe the ORIC did, since it also has ELSE, where earlier 6502 versions didn't.  The ORIC came out after the Atari version.
 

The ORIC does support integers, but you have to specify them with the % sign at the end, which takes longer to parse, but at least it supports them.
Example:
A%=1:DIM I%(size)

Link to comment
Share on other sites

  • 6 months later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...