OT : DOS 6.20 QBasic, GW-Basic - syntax semantics query 
Author Message
 OT : DOS 6.20 QBasic, GW-Basic - syntax semantics query




Quote:

> > I know that VBScript is not exactly DOS 6.20 QBasic or GW-Basic ; but I
> > have a syntax semantics query about code written in GW-Basic and now
> > running in QBasic from DOS 6.20 running in XP sp3.
> > The line is, with the weird term marked,

> > 2390 T = OT: M = OM: O = B(SJ, (M - 1)) + T
> > ^^^^^^^^^^^^^^

> > It is clear that B is a small non-negative integer, perhaps in the range
> > 0 to 29; OM is either 3 or 4; OT is an integer in the range 1 to 31 ; SJ
> > is either 0 or 1. The result O is evidently a small integer too.

> > But what does B(SJ, (M - 1)) mean, and how?

> B() is just a multi-dimensional array. The selected item (O) is column SJ (SJ
> should be a number between zero and... I don't remember), row M - 1 (M should
> be a number between one and whatever).

B(x,y) indeed looks like a two-dimensional array.  But what does that
code mean when B is, as I said, a small integer?

--
  (c) John Stockton, near London, UK.  Posting with Google.

 Web:  <URL: http://www.*-*-*.com/ ;
 FAQish topics, acronyms, links, etc.; Date, Delphi, JavaScript, ....|



Tue, 03 May 2011 07:06:31 GMT  
 OT : DOS 6.20 QBasic, GW-Basic - syntax semantics query


Quote:





>> > I know that VBScript is not exactly DOS 6.20 QBasic or GW-Basic ; but I
>> > have a syntax semantics query about code written in GW-Basic and now
>> > running in QBasic from DOS 6.20 running in XP sp3.

>> > The line is, with the weird term marked,

>> > 2390 T = OT: M = OM: O = B(SJ, (M - 1)) + T
>> > ^^^^^^^^^^^^^^

>> > It is clear that B is a small non-negative integer, perhaps in the
>> > range
>> > 0 to 29; OM is either 3 or 4; OT is an integer in the range 1 to 31 ;
>> > SJ
>> > is either 0 or 1. The result O is evidently a small integer too.

>> > But what does B(SJ, (M - 1)) mean, and how?

>> B() is just a multi-dimensional array. The selected item (O) is column SJ
>> (SJ
>> should be a number between zero and... I don't remember), row M - 1 (M
>> should
>> be a number between one and whatever).

> B(x,y) indeed looks like a two-dimensional array.  But what does that
> code mean when B is, as I said, a small integer?

> --
>  (c) John Stockton, near London, UK.  Posting with Google.

> Web:  <URL:http://www.merlyn.demon.co.uk/>
> FAQish topics, acronyms, links, etc.; Date, Delphi, JavaScript, ....|

Did you try Googling for 2390 T = OT: M = OM: O = B(SJ, (M - 1)) + T
?


Tue, 03 May 2011 10:25:14 GMT  
 OT : DOS 6.20 QBasic, GW-Basic - syntax semantics query

"MikeB" <m.byerleyATVerizonDottieNettie> skrev i meddelandet

Quote:





>> > I know that VBScript is not exactly DOS 6.20 QBasic or GW-Basic ; but I
>> > have a syntax semantics query about code written in GW-Basic and now
>> > running in QBasic from DOS 6.20 running in XP sp3.

>> > The line is, with the weird term marked,

>> > 2390 T = OT: M = OM: O = B(SJ, (M - 1)) + T
>> > ^^^^^^^^^^^^^^

>> > It is clear that B is a small non-negative integer, perhaps in the
>> > range
>> > 0 to 29; OM is either 3 or 4; OT is an integer in the range 1 to 31 ;
>> > SJ
>> > is either 0 or 1. The result O is evidently a small integer too.

>> > But what does B(SJ, (M - 1)) mean, and how?

>> B() is just a multi-dimensional array. The selected item (O) is column SJ
>> (SJ
>> should be a number between zero and... I don't remember), row M - 1 (M
>> should
>> be a number between one and whatever).

> B(x,y) indeed looks like a two-dimensional array.  But what does that
> code mean when B is, as I said, a small integer?

> --
>  (c) John Stockton, near London, UK.  Posting with Google.

> Web:  <URL:http://www.merlyn.demon.co.uk/>
> FAQish topics, acronyms, links, etc.; Date, Delphi, JavaScript, ....|

The value in B(x,y) for sure can be a small integer.

/Henning



Tue, 03 May 2011 23:01:55 GMT  
 OT : DOS 6.20 QBasic, GW-Basic - syntax semantics query
Quote:





>>> I know that VBScript is not exactly DOS 6.20 QBasic or GW-Basic ; but I
>>> have a syntax semantics query about code written in GW-Basic and now
>>> running in QBasic from DOS 6.20 running in XP sp3.

>>> The line is, with the weird term marked,
>>> 2390 T = OT: M = OM: O = B(SJ, (M - 1)) + T
...
> B(x,y) indeed looks like a two-dimensional array.  But what does that
> code mean when B is, as I said, a small integer?

...

Well, from the snippet alone B() _could_ also be a function.

What it means is solely dependent upon the use made of the resulting
variable "O" and is impossible to tell from the isolated line.

--



Tue, 03 May 2011 23:39:54 GMT  
 
 [ 4 post ] 

 Relevant Pages 

1. ******Need OLD BASIC (BASICA?) for current DOS (6.2)

2. Qbasic/Quickbasic/GW-Basic

3. BASICA on a Pentium (MS-DOS 6.2)

4. BASICA on a Pentium (MS-DOS 6.2)

5. Creating a Dos 6.2 Boot Disk Under Win '95

6. Creating a Dos 6.2 Boot Disk Under Win '95

7. GW in GW-BASIC

8. OT: Host needed for gwbasic.org

9. Accessing database files from QBasic 4.5, Visual Basic for DOS

10. Checking Keyboard Buffer in Visual Basic for DOS or QBasic

11. BASIC POINTER SEMANTICS

12. Checking Keyboard Buffer in Visual Basic for DOS or QBasic

 

 
Powered by phpBB® Forum Software