Re: nodelist.bas

 BBS: Inland Empire Archive
Date: 02-19-93 (08:45)             Number: 395
From: QUINN TYLER JACKSON          Refer#: NONE
  To: ZACK JONES                    Recvd: NO  
Subj: Re: nodelist.bas               Conf: (2) Quik_Bas
 QTJ> 'DIALECT:       PDS 7.1 or VBDOS 1.0

 ZJ> I'd say it's more for VB/DOS than PDS or QB.

Yeah.  VBDOS does that thing with STATIC and underscores.
Maybe the REMs in my code should include a warning about

 QTJ> '               (My version is 10 times faster than his was.)

 ZJ> Big deal - it's nice that you can optimize code - but
 ZJ> why rub his  ZJ>  face in it?

No rubbing intended.  I took real steps in optimizing NODELIST.BAS to the
point that it was ten times faster.  Coridon can look at
that line and say: "What did he do to make it so much
faster, and how can I do that in the future with my code to
achieve the same result, so that next time I post, NO ONE
can make it faster?"

That way, everyone learns.  Now, had I not mentioned that,
someone might have thought that mine was just an alternate
method.  They might just say: "Well, I've got Coridon's
NODELIST.BAS, and Quinn's doesn't LOOK any different on the
surface, so why bother downloading it and looking at the

The promise of faster algorithms might be what entices them to look at both
and really look at what makes one type of programming
faster than another.  A factor of ten is no joke, and makes
people think.  Then, when they see how to make a loop just
a little faster, they can use the same or similar
techniques in their code.  Coridon gets the credit for the
original NODELIST.BAS.  I get the credit for the
optimization.  The echo reader gets the credit for learning
how to omtimize their code from practical examples.  That
was my only intention of mentioning it that way.  No
toestepping intended.

For example, one of the things Coridon's code did, which
MANY programmers do was:

        END IF

Now, that loops 15,000 times let's say.  If the SOMECONDITION only occurs 100
times on average, we've looked 14,900 times to many, and
that increases the overall execution time.  By only looking
for SOMECONDITION when all other, more common situations
are handled, we increase speed by many factors.

Would you prefer I comment my optimizations in the future

with sentences like that, so that people can see what I've
done directly?


 ZJ> Two big gotchas!  As you well know the underscore is
 ZJ> used as the continuation
 ZJ> character is QB & PDS - I had to do some chopping of
 ZJ> the code to get it to
 ZJ> work under PDS - ran fine under VB/DOS.

Yeah.  I love the underscore.  How about I prepare special
QUIK_BAS versions that use a '.' instead?

 QTJ> STATIC SUB FlushBuffers (FlushFileHandle,
 QTJ> NodeList() AS NodelistType)
 ZJ>        |---->------> need to move this a bit to work under PDS ----->

 ZJ> Please remember is this the QUIK_BAS echo - code posted here needs to run
 ZJ> under QB45.

Is that a rule?  If it is, I'll obey it. ;)

 ZJ> Quinn, you and I are going to battle with each other way too often and I
 ZJ> don't like it.  Do me a favor and netmail me your voice number - I'd like
 ZJ> to talk on my dime.

I don't see why we should battle at all.  I've already said that if you post
rules, I'd obey them to the letter.  If QB45 it is, then
QB45 it will be.  I see POSTIT as being a bigger issue than
BASIC dialect allowed, but I agree to abide anyway.
Coridon has joined the project team.  If his toes hurt, he
has been too put off to say so.  I think he enjoys the idea
of the echowide project I've proposed.  Now, had there been
a rule stating 'echowide projects are the jurisdiction of
the mod.' I would have obeyed.  My personal opinion is that
the rules should deal with the more important things,
however.  Like POSTIT use, copyright notices. Etc.
Everyone wants in on the QBCIMR project.  I don't think it
will hurth anyone, unless coding and cooperation hurts
QUIK_BAS.  I thought that's what everyone wanted.  No
argument with you intended.  I just showed some initiative,
that's all.

(604) 421-3301.  Best time to catch me these days.... business hours.

Keep your spurs sharp and your horse well-oiled,


--- Maximus/2 2.01wb
 * Origin: The Nibble's Roost, Richmond BC Canada 604-244-8009 (1:153/918)
Outer Court
Echo Basic Postings

Books at Amazon:

Back to BASIC: The History, Corruption, and Future of the Language

Hackers: Heroes of the Computer Revolution (including Tiny BASIC)

Go to: The Story of the Math Majors, Bridge Players, Engineers, Chess Wizards, Scientists and Iconoclasts who were the Hero Programmers of the Software Revolution

The Advent of the Algorithm: The Idea that Rules the World

Moths in the Machine: The Power and Perils of Programming

Mastering Visual Basic .NET