[alt.religion.computers] ap, Windows BASIC

mathew@mantis.co.uk (Giving C News a *HUG*) (06/13/91)

phil@ux1.cso.uiuc.edu (Phil Howard KA9WGN) writes:
> tml@extro.ucc.su.OZ.AU (Tim Long) writes:
> >1) To have a freely available general purpose interpretive language on
> >UNIX systems.  (As opposed to the many more special purpose ones such
> >as awk and the shell).  This can be re-phrased as: To have a UNIX
> >language like DOS has BASIC.
> 
> First thing I do after installing DOS on a PC is find BASIC and erase it.

Same here.  In fact, since the BASIC supplied with this machine was on a
separate disk, I didn't even bother to install it in the first place.

Microsoft has now announced Visual BASIC, a mutant BASIC with Windows.  This
strikes me as being just what the world did NOT need.  The Atari ST has a
number of BASICs similar in concept to Visual BASIC, and in my experience the
PD GEM programs written in BASIC are klunky, unreliable, and suffer from
bizarre user-interface weirdness.

Until now, PD Windows 3.0 programs have mostly been of fairly good quality. 
I confidently predict that Visual BASIC will change that.


mathew

 

mroussel@alchemy.chem.utoronto.ca (Marc Roussel) (06/15/91)

In article <ieFH49w164w@mantis.co.uk> mathew@mantis.co.uk
(Giving C News a *HUG*) writes:
>Microsoft has now announced Visual BASIC, a mutant BASIC with Windows.  This
>strikes me as being just what the world did NOT need.
[...]
>Until now, PD Windows 3.0 programs have mostly been of fairly good quality. 
>I confidently predict that Visual BASIC will change that.

     Isn't this a rather mean-spirited attitude?  The fact is that the
average person has an occasional need to write a simple program in an
easy language.  BASIC (along with a few other tools) fills that need.
Saying that the world does not need BASIC (or something like it) is
essentially saying that only the high priesthood of the programming
profession should ever write computer programs.  If people want BASIC,
let them have it.
     PD programs come with no guarantees.  If I write something and make it
available to others it's because I think that someone else might want
it.  If you don't like it or it crashes your machine, there's a DEL
command in DOS (and rm in Unix, and so on...) to deal with that.

				Marc R. Roussel
                                mroussel@alchemy.chem.utoronto.ca

cjeffery@optima.UUCP (Clinton Jeffery) (06/15/91)

> [Some person, agreeing with some other person's BASIC-bashing, writes]:
> Until now, PD Windows 3.0 programs have mostly been of fairly good quality. 
> I confidently predict that Visual BASIC will change that.

What kind of an elitist statement is this?  You think only people who can
spend $500 or more (on C compiler and tools) should be allowed to write
programs for Windows?  Hogwash!  There have been so few PD Windows 3.0
programs written that their "quality" is irrelevant.  Now, I will be the
first to agree with you that BASIC was the WRONG language, and that
Visual BASIC is just another sleazy money-grubbing Microsoft product,
but I feel that making the programming task more available to more of
the proletarian masses is a good concept in general.  Ideally it should
be free, ideally it should NOT be BASIC (or C), and ideally it should not
be for Windows, but people will have to make do with reality I guess.

mathew@mantis.co.uk (Giving C News a *HUG*) (06/17/91)

mroussel@alchemy.chem.utoronto.ca (Marc Roussel) writes:
> In article <ieFH49w164w@mantis.co.uk> mathew@mantis.co.uk
> (Giving C News a *HUG*) writes:
> >Microsoft has now announced Visual BASIC, a mutant BASIC with Windows.  This
> >strikes me as being just what the world did NOT need.
> [...]
> >Until now, PD Windows 3.0 programs have mostly been of fairly good quality. 
> >I confidently predict that Visual BASIC will change that.
> 
>      Isn't this a rather mean-spirited attitude?  The fact is that the
> average person has an occasional need to write a simple program in an
> easy language.  BASIC (along with a few other tools) fills that need.

That's "Yes Minister" logic. "We must do something. This is something.
Therefore we must do this."

> Saying that the world does not need BASIC (or something like it) is
> essentially saying that only the high priesthood of the programming
> profession should ever write computer programs.

Utter crap.  It's saying that people should be given proper programming
languages to write in, so that they can learn to write properly and join the
programming profession, rather than being mentally stifled by BASIC and left
thinking that WHILE loops are a pretty neat idea.

>      PD programs come with no guarantees.  If I write something and make it
> available to others it's because I think that someone else might want
> it.  If you don't like it or it crashes your machine, there's a DEL
> command in DOS (and rm in Unix, and so on...) to deal with that.

Indeed. Up until now, every PD or Shareware Windows program I've seen has
worked in a fairly acceptable fashion and been at least moderately well
crafted. I am merely expressing the opinion that I would like to have things
stay that way, rather than have to search for 5% of good programs amongst the
95% of complete crap written in BASIC.

In short, PD Windows software is on the whole better than PD non-Windows
software. I suspect that this is related to the non-feasability of using
BASIC for Windows development.

As I said in my article, when BASIC for the ST started to support GEM
programming, I noticed the quality of GEM-based programs dropping
dramatically.

It may, of course, all be coincidence. If it is, I'll be quite happy to use
well-crafted BASIC programs.


mathew

 

mathew@mantis.co.uk (Giving C News a *HUG*) (06/17/91)

cjeffery@optima.UUCP (Clinton Jeffery) writes:
> > [Some person, agreeing with some other person's BASIC-bashing, writes]:
> > Until now, PD Windows 3.0 programs have mostly been of fairly good quality.
> > I confidently predict that Visual BASIC will change that.
> 
> What kind of an elitist statement is this?  You think only people who can
> spend $500 or more (on C compiler and tools) should be allowed to write
> programs for Windows?

No. I don't think C compilers should be $500. I got C, Modula-2, and a set of
GEM developer's tools for the ST for less than $300.

How much is Turbo 'Pascal' for Windows these days?  It may not be Pascal, but
it's better than BASIC.

>                                    There have been so few PD Windows 3.0
> programs written that their "quality" is irrelevant.

What a bizarre attitude.

>                                                  Now, I will be the
> first to agree with you that BASIC was the WRONG language, and that
> Visual BASIC is just another sleazy money-grubbing Microsoft product,
> but I feel that making the programming task more available to more of
> the proletarian masses is a good concept in general.

Sorry, but what on earth led you to believe that I would disagree with any of
that?


mathew

 

jbtubman@beetle.arc.ab.ca (Jim Tubman) (06/18/91)

In article <ieFH49w164w@mantis.co.uk> mathew@mantis.co.uk (Giving C News a *HUG*) writes:

   Microsoft has now announced Visual BASIC, a mutant BASIC with Windows.  This
   strikes me as being just what the world did NOT need.  The Atari ST has a
   number of BASICs similar in concept to Visual BASIC, and in my experience the
   PD GEM programs written in BASIC are klunky, unreliable, and suffer from
   bizarre user-interface weirdness.

   Until now, PD Windows 3.0 programs have mostly been of fairly good quality. 
   I confidently predict that Visual BASIC will change that.


   mathew


My, I wish I could make such confident pronouncements about stuff I've
never seen.

Seriously though, I've seen quite a few articles about Visual BASIC in
the trade press lately, all of them positive, some of then rabidly so.
Most of the articles start by advising the reader to abandon any
preconceptions that they have about old versions of BASIC and take the
product on its own merits.

Perhaps someone out there who has actually used Visual BASIC might
post a mini-review to help clear things up.

--Jim
--
-------------------------------------------------------------------------------
James B. Tubman				 Alberta Research Council
Research Officer	                 Advanced Computing & Engineering Dept.
jbtubman@arcsun.arc.ab.ca		 3rd Floor
jbtubman@noah.arc.ab.ca			 6815 - 8 Street NE
Phone: (403) 297-2652			 Calgary, Alberta
Fax:   (403) 275-3003			 Canada T2E 7H7
-------------------------------------------------------------------------------
"A just machine to make big decisions,
 Programmed by fellows with compassion and vision."		-- Donald Fagan
-------------------------------------------------------------------------------

mathew@mantis.co.uk (Giving C News a *HUG*) (06/18/91)

jbtubman@beetle.arc.ab.ca (Jim Tubman) writes:
> My, I wish I could make such confident pronouncements about stuff I've
> never seen.
> 
> Seriously though, I've seen quite a few articles about Visual BASIC in
> the trade press lately, all of them positive, some of then rabidly so.

The trade press were rabidly positive about OS/2 1.0.

> Most of the articles start by advising the reader to abandon any
> preconceptions that they have about old versions of BASIC and take the
> product on its own merits.

Look, is it BASIC or is it not?  If it's nothing like BASIC and Microsoft are
just calling it BASIC, then that's stupid marketing.  They might as well call
Word for Windows "Visual EDLIN".

If it *is* BASIC, or BASIC with a few extensions, as I expect, then I stand
by my comments.


mathew

 

F0O@psuvm.psu.edu (06/18/91)

>> Saying that the world does not need BASIC (or something like it) is
>> essentially saying that only the high priesthood of the programming
>> profession should ever write computer programs.

>Utter crap.  It's saying that people should be given proper programming
>languages to write in, so that they can learn to write properly and join the
>programming profession, rather than being mentally stifled by BASIC and left
>thinking that WHILE loops are a pretty neat idea.

   Don't want to start a language war, but oh well.  Have you used
Microsoft QuickBasic 4.0 or better?  It has some nice features I wish were
in Pascal or other languages.  Like QB's SELECT CASE statement; much more
powerful then Pascals.  It is a fully structured language except for the
fact you can't have nested blocks as in Pascal.  One of the great things
I like about the QB environment is when you press the F2 key, a window
pops up with a list of all your procedures/functions.  Click on the one
you want to look at and bingo.  Very nice.  Also, not having to define the
lengths of your strings is nice(but has it's own bag on worms in certain
cases).
   Besides, for a windows program, or any other program for that matter;
what's more important is not so much the language it's written in, but the
person writing the program.
   Just my thoughts for the day!

                                                           [Tim]

mathew@mantis.co.uk (Giving C News a *HUG*) (06/19/91)

F0O@psuvm.psu.edu writes:
>    Don't want to start a language war, but oh well.  Have you used
> Microsoft QuickBasic 4.0 or better?

I've used QuickBASIC [dies of shame] but I don't remember the version number.

>                                     It has some nice features I wish were
> in Pascal or other languages.  Like QB's SELECT CASE statement; much more
> powerful then Pascals.

What, you mean it allows general boolean expressions for each CASE, like
Clipper 5.0 does?  That makes it just syntactic sugar; most other languages
have the same feature available, they just call it IF...ELSEIF...ENDIF.

>                         It is a fully structured language except for the
> fact you can't have nested blocks as in Pascal.

That's like saying it's fully object-oriented except it doesn't have
inheritance...

>                                                One of the great things
> I like about the QB environment is when you press the F2 key, a window
> pops up with a list of all your procedures/functions.  Click on the one
> you want to look at and bingo.  Very nice.

My editor does that, for C, C++, Pascal, Modula-2, Clipper, or any other
language you care to tell it about.

>                                          Also, not having to define the
> lengths of your strings is nice(but has it's own bag on worms in certain
> cases).

You can implement arbitrary-size strings in C++ quite easily, and the same
goes for Modula-2. Turbo 'Pascal' has them as well.


mathew

 

coates@uc780.umd.edu (06/19/91)

In a previous article, F0O@psuvm.psu.edu wrote:
> 
>>> Saying that the world does not need BASIC (or something like it) is
>>> essentially saying that only the high priesthood of the programming
>>> profession should ever write computer programs.
> 
>>Utter crap.  It's saying that people should be given proper programming
>>languages to write in, so that they can learn to write properly and join the
>>programming profession, rather than being mentally stifled by BASIC and left
>>thinking that WHILE loops are a pretty neat idea.
> 

Although, BASIC MAY not be the langauge of professional or serious students
of programming, Visual BASIC may be good for some of the masses. I say for
some because others may need something less complex than even BASIC.
The average quality of Windows apps may fall, but the power of Windows
will to an extent be available to more than the programming elite. I think
that will be a good thing. (The power being the ease of use and efficay
of GUI. 

**************************************************************************
*                     Elliott Coates, washington dc                      *
*                         coates@uc780.umd.edu                           *
*                             coates@uc780.bitnet                        *
**************************************************************************

coates@uc780.umd.edu (06/19/91)

The last line of my reply to this subject should read:
(The power being the ease of use and efficacy of GUI.)

**************************************************************************
*                     Elliott Coates, washington dc                      *
*                         coates@uc780.umd.edu                           *
*                             coates@uc780.bitnet                        *
**************************************************************************

rogerhef@matt.ksu.ksu.edu (Roger Heflin) (06/20/91)

In <mukq411w164w@mantis.co.uk> mathew@mantis.co.uk (Giving C News a *HUG*) writes:

>Look, is it BASIC or is it not?  If it's nothing like BASIC and Microsoft are
>just calling it BASIC, then that's stupid marketing.  They might as well call
>Word for Windows "Visual EDLIN".

>If it *is* BASIC, or BASIC with a few extensions, as I expect, then I stand
>by my comments.

You yell about BASIC being bad.  Have you ever used Microsoft QuickBasic?
It is structured and considerable easier to use than any other language.  
The language look pretty much like any other structured language, such as
C or Pascal, the only limitation that QB has is it does not have pointers,
otherwise it is at least as good as C or Pascal for good coding form.  There
are even several application programs that were written in this BASIC.  This
BASIC has full recursive modules, functions, and structures.  You are reading
too much into the word BASIC.  You are taking what GWBASIC looks like and    
most of the other old BASIC versions and assuming that all BASICS are the
same,  they are not.  The BASIC has more than a few extensions.  I can write
a bad program in it, but I can do that in any language.  I expect       
Microsoft is basing Visual Basic on this.  The QB line has existed for
several years, they did just not give it out for free.


> 
--
Rogerhef@Matt.ksu.ksu.edu                        Roger Heflin
                                                 EECE Grad Student
                                                 (913) 532-5600

rogerhef@matt.ksu.ksu.edu (Roger Heflin) (06/20/91)

In <4k4q47w164w@mantis.co.uk> mathew@mantis.co.uk (Giving C News a *HUG*) writes:

>What, you mean it allows general boolean expressions for each CASE, like
>Clipper 5.0 does?  That makes it just syntactic sugar; most other languages
>have the same feature available, they just call it IF...ELSEIF...ENDIF.

>>                                                One of the great things
>> I like about the QB environment is when you press the F2 key, a window
>> pops up with a list of all your procedures/functions.  Click on the one
>> you want to look at and bingo.  Very nice.

>My editor does that, for C, C++, Pascal, Modula-2, Clipper, or any other
>language you care to tell it about.

>>                                          Also, not having to define the
>> lengths of your strings is nice(but has it's own bag on worms in certain
>> cases).

>You can implement arbitrary-size strings in C++ quite easily, and the same
>goes for Modula-2. Turbo 'Pascal' has them as well.

Yes your editor can do that with C,C++,Pascal, .... but you had to take
time to set it up to work correctly, QB does that itself.  Does your
editor also do full debugging?  QB's debugger surpasses any debugger
I have found on any Unix machine on relibility and usability.  I have
never had a QB program 'coredump'.  It is a considerably safer programming
enviroment compared to C or C++.  
--
Rogerhef@Matt.ksu.ksu.edu                        Roger Heflin
                                                 EECE Grad Student
                                                 (913) 532-5600

<F0O@psuvm.psu.edu> (06/20/91)

In article <4k4q47w164w@mantis.co.uk>, mathew@mantis.co.uk (Giving C News a
*HUG*) says:

>F0O@psuvm.psu.edu writes:

>>                                     It has some nice features I wish were
>> in Pascal or other languages.  Like QB's SELECT CASE statement; much more
>> powerful then Pascals.

>What, you mean it allows general boolean expressions for each CASE, like
>Clipper 5.0 does?  That makes it just syntactic sugar; most other languages
>have the same feature available, they just call it IF...ELSEIF...ENDIF.

   Two examples should get my point across:

   This segment will match strings that are exactly equal to "everything"
the current value of AnotherString, or that fall between "nuts" and "soup"
in alphabetical order

   SELECT CASE AStringVariable
      CASE "everything", "nuts" TO "soup", AnotherString
      ...
   END SELECT

   This code will compare ANumericVariable for numbers between 1 and 4,
7 to 9, 11, 13, or if ANumericVariable > MaxNumber

   SELECT CASE ANumericVariable
      CASE 1 to 4, 7 to 9, 11, 13, IS > MaxNumber
      ...
      CASE ELSE
      ...
   END SELECT


>>                         It is a fully structured language except for the
>> fact you can't have nested blocks as in Pascal.


>That's like saying it's fully object-oriented except it doesn't have
>inheritance...

   Could be, except I don't use nested blocks very often, so I don't miss
it too much.

>> I like about the QB environment is when you press the F2 key, a window
>> pops up with a list of all your procedures/functions.  Click on the one
>> you want to look at and bingo.  Very nice.

>My editor does that, for C, C++, Pascal, Modula-2, Clipper, or any other
>language you care to tell it about.

   Which editor is that, and how hard was it to set up?


                                                               [Tim]

mwm@pa.dec.com (Mike (My Watch Has Windows) Meyer) (06/20/91)

In article <1991Jun20.034708.2816@maverick.ksu.ksu.edu> rogerhef@matt.ksu.ksu.edu (Roger Heflin) writes:
   >> I like about the QB environment is when you press the F2 key, a window
   >> pops up with a list of all your procedures/functions.  Click on the one
   >> you want to look at and bingo.  Very nice.

   >My editor does that, for C, C++, Pascal, Modula-2, Clipper, or any other
   >language you care to tell it about.

   Yes your editor can do that with C,C++,Pascal, .... but you had to take
   time to set it up to work correctly, QB does that itself.

You mean QB already understands C, C++, Pascal and ... ? That's
impressive. If it doesn't, then at best it's at the same level, with
one language it already understands. More likely it isn't up to that
level, as it isn't going to be that usefull for multi-language
projects.

Of course, if I have to use QB commands (if it's one of the
pain-in-the-ass mouse/function key editors, forget it) and can't
configure it to my habits, then it's going to be an incredible pain to
use. Given the choice, I'd rather teach an editor I know about a
new language than teach an editor I don't know how to look like an
editor I do know.

Is QB one of those awfull "integrated environments" so loved on
mono-tasking environments? In general, they're just a pain, but better
than the alternatives. I much prefer the system I've got, where the
editor/compiler/debugger all run as seperate tasks and commmunicate
with each other via IPC. That way, I can use any editor I want, and
not have to worry about what other people are doing.

  Does your editor also do full debugging?  QB's debugger surpasses any
  debugger I have found on any Unix machine on relibility and usability.

That's not saying very much.

   I have never had a QB program 'coredump'.  It is a considerably safer
   programming enviroment compared to C or C++.  

Neither is that.

	<mike
--
Lather was thirty years old today,			Mike Meyer
They took away all of his toys.				mwm@pa.dec.com
His mother sent newspaper clippings to him,		decwrl!mwm
About his old friends who'd stopped being boys.

mathew@mantis.co.uk (Giving C News a *HUG*) (06/21/91)

rogerhef@matt.ksu.ksu.edu (Roger Heflin) writes:
> In <mukq411w164w@mantis.co.uk> mathew@mantis.co.uk (Giving C News a *HUG*) wr
> >If it *is* BASIC, or BASIC with a few extensions, as I expect, then I stand
> >by my comments.
> 
> You yell about BASIC being bad.  Have you ever used Microsoft QuickBasic?

Yes. As a matter of fact I have.

> It is structured and considerable easier to use than any other language.

It may be "structured", but it isn't easier to use than (for example) LOGO.
  
> The language look pretty much like any other structured language, such as
> C or Pascal, the only limitation that QB has is it does not have pointers,

That's an *ENORMOUS* limitation.  It really really limits the sorts of data
structures you can use in an imperative (C-like) language.  There are
alternatives to pointers, but BASIC doesn't have them either.

> This BASIC has full recursive modules, functions, and structures.

Yes, but what about all the things it *doesn't* have?  I mean, these days
macro assemblers support recursive modules, functions, and structures.

>                                                           You are reading
> too much into the word BASIC.  You are taking what GWBASIC looks like and    
> most of the other old BASIC versions and assuming that all BASICS are the
> same,  they are not.  The BASIC has more than a few extensions.

I have *never* used GWBASIC.  All the BASICs I've used for the last ten years
have had recursion, functions, local variables, multi-line IF...THEN...ELSE,
REPEAT...UNTIL, and so on.

They're *still* crap.

>                                                          I can write
> a bad program in it, but I can do that in any language.

Right.  But can you write a *good* program in BASIC?  Can you write a program
which is as good as one written in Modula-2, Pascal, Smalltalk, Scheme, C++..?


mathew

 

mathew@mantis.co.uk (Giving C News a *HUG*) (06/21/91)

rogerhef@matt.ksu.ksu.edu (Roger Heflin) writes:
> In <4k4q47w164w@mantis.co.uk> mathew@mantis.co.uk (Giving C News a *HUG*) wri
> >>                                                One of the great things
> >> I like about the QB environment is when you press the F2 key, a window
> >> pops up with a list of all your procedures/functions.  Click on the one
> >> you want to look at and bingo.  Very nice.
> 
> >My editor does that, for C, C++, Pascal, Modula-2, Clipper, or any other
> >language you care to tell it about.
> 
> Yes your editor can do that with C,C++,Pascal, .... but you had to take
> time to set it up to work correctly,

No I didn't.  I just put the installation disk in, typed SETUP, and answered
a few questions.  Then I loaded my C program, typed CTRL-G, and it gave me a
list of all the procedures and functions I could jump to.  I then loaded a
Clipper program and did the same thing, and that worked as well.

> Does your editor also do full debugging?

No, my debugger does full debugging.

>                                   QB's debugger surpasses any debugger
> I have found on any Unix machine on relibility and usability.

So?  I thought we were talking about DOS and Windows programming.  I wouldn't
hold up UNIX as a good example of anything much.

> I have never had a QB program 'coredump'.  It is a considerably safer programming
> enviroment compared to C or C++.  

That's mainly because it doesn't have pointers, which is a pretty big price
to pay.  I'd rather be allowed to use pointers, and have the machine bring up
the appropriate line of source code whenever a pointer error occurs.


mathew

 

rogerhef@matt.ksu.ksu.edu (Roger Heflin) (06/21/91)

In <MWM.91Jun20110422@raven.pa.dec.com> mwm@pa.dec.com (Mike (My Watch Has Windows) Meyer) writes:

>You mean QB already understands C, C++, Pascal and ... ? That's
>impressive. If it doesn't, then at best it's at the same level, with
>one language it already understands. More likely it isn't up to that
>level, as it isn't going to be that usefull for multi-language
>projects.

No it doesn't understand C.. but Microsofts other integrated enviroments
do and all of the work exactly the same, they also work the same as most
all of the windows applications.

>Of course, if I have to use QB commands (if it's one of the
>pain-in-the-ass mouse/function key editors, forget it) and can't
>configure it to my habits, then it's going to be an incredible pain to
>use. Given the choice, I'd rather teach an editor I know about a
>new language than teach an editor I don't know how to look like an
>editor I do know.

Ah, a completely closed mind.

>Is QB one of those awfull "integrated environments" so loved on
>mono-tasking environments? In general, they're just a pain, but better
>than the alternatives. I much prefer the system I've got, where the
>editor/compiler/debugger all run as seperate tasks and commmunicate
>with each other via IPC. That way, I can use any editor I want, and
>not have to worry about what other people are doing.

The integrated enviroment that you so had acts just like the rest of the
windows enviroment.  You bitch about those "pain-in-the-ass mouse/function
key editors", what editor are you using that doesn't use function keys?
Emacs, the editor with many shift keys?  That is only easier to use after
you have spent months learing the key sequences.  I can train someone to use
the QB editor in a day, you cannot say that for your editor.


--
Rogerhef@Matt.ksu.ksu.edu                        Roger Heflin
                                                 EECE Grad Student
                                                 (913) 532-5600

mathew@mantis.co.uk (Giving C News a *HUG*) (06/21/91)

F0O@psuvm.psu.edu writes:
> In article <4k4q47w164w@mantis.co.uk>, mathew@mantis.co.uk (Giving C News a
> *HUG*) says:
> >What, you mean it allows general boolean expressions for each CASE, like
> >Clipper 5.0 does?  That makes it just syntactic sugar; most other languages
> >have the same feature available, they just call it IF...ELSEIF...ENDIF.
> 
>    Two examples should get my point across:
> 
>    This segment will match strings that are exactly equal to "everything"
> the current value of AnotherString, or that fall between "nuts" and "soup"
> in alphabetical order
> 
>    SELECT CASE AStringVariable
>       CASE "everything", "nuts" TO "soup", AnotherString
>       ...
>    END SELECT

That's just
   IF AStringVariable = "everything" OR AStringVariable = AnotherString OR
      (AStringVariable > "nuts" AND AStringVariable < "soup")
   ...
   ELSE
   ...
   ENDIF

In other words, the SELECT CASE you mention is just syntactic sugar for
IF...ELSE...ENDIF.

If you happen to prefer the CASE syntax, in C++ you could write yourself a
quick macro.  And if you want to do lots of comparisons like the one you
mention, you could write yourself a quick macro in C++, or a function in
Modula-2 or Pascal.

>    This code will compare ANumericVariable for numbers between 1 and 4,
> 7 to 9, 11, 13, or if ANumericVariable > MaxNumber
> 
>    SELECT CASE ANumericVariable
>       CASE 1 to 4, 7 to 9, 11, 13, IS > MaxNumber
>       ...
>       CASE ELSE
>       ...
>    END SELECT

IF ANumericVariable IN { 1,2,3,4, 7,8,9, 11, 13 } OR ANumericVariable >
   MaxNumber
   ...
ELSE
   ...
ENDIF

Pascal and Modula-2 both have suitable set operations to do this. It'll be a
bit more work in C++, but not much.

In Lisp, both examples are pretty trivial (cond ...) expressions.

> >>                         It is a fully structured language except for the
> >> fact you can't have nested blocks as in Pascal.
> >That's like saying it's fully object-oriented except it doesn't have
> >inheritance...
> 
>    Could be, except I don't use nested blocks very often, so I don't miss
> it too much.

Precisely!  Because you don't have the feature, you've never used it. So you
don't know how useful and important it is. And then when you move up to a
better language, you're trapped in the BASIC mindset.

> >> I like about the QB environment is when you press the F2 key, a window
> >> pops up with a list of all your procedures/functions.  Click on the one
> >> you want to look at and bingo.  Very nice.
> >My editor does that, for C, C++, Pascal, Modula-2, Clipper, or any other
> >language you care to tell it about.
> 
>    Which editor is that, and how hard was it to set up?

Brief. I put the disk in and typed "SETUP", and told it which languages I
would be using. Selected from a menu.

Oh, and I wrote a couple of pages of code to re-bind the editor keys to what
I'm used to.  I take it I could do the same with QuickBASIC?


mathew

 

neeri@iis.ethz.ch (Matthias Ulrich Neeracher) (06/21/91)

In article <1991Jun20.034205.2661@maverick.ksu.ksu.edu> rogerhef@matt.ksu.ksu.edu (Roger Heflin) writes:
[I kept the crossposting to comp.windows.ms.programmer, but I don't read it, so
 I set the followup to alt.religion.computers]

>You yell about BASIC being bad.  Have you ever used Microsoft QuickBasic?

This post wasn't addressed to me, but I'll anwer anyway. I have not used
Microsoft Quickbasic. I have used BASIC on a Commodore 8032 and on an Epson HX
7 Years ago. I had to use GFA Basic on an Atari 1 year ago. I found that it is
definitely, absolutely *impossible* to write a program that would run both on
GFA and on the other two dialects: While the other dialects *required* line
numbers, GFA *forbids* them. One big problem with BASIC is that there are so
many of them. (BTW, has anyone here seen the 1978 ANSI BASIC standard ? I saw
it mentioned in a book, but I don't think it was widely implemented. How would
standard BASIC look like ? Are there efforts for a revised standard (BASIC 9X :-)
underway ?)

>It is structured and considerable easier to use than any other language.

So, what other languages did you write a considerable amount of code (say more
than 1000 lines) in ? I have used Pascal, Modula-2, Prolog, K&R C, ANSI C, and C++. All
of them were considerably more comfortable to use, once you knew them.
And I don't think Pascal is that much more difficult to learn than BASIC.
   Maybe we differ in our use of 'using' a programming language. I don't consider
50 line programs 'use'. When I did most of my BASIC programming, writing a 300
line program was extremely difficult, with only global variables available and
only two characters of the name significant. Modern dialects seem to have
improved, but I still see lots of disadvantages of BASIC and no advantages.

>The language look pretty much like any other structured language, such as
>C or Pascal, the only limitation that QB has is it does not have pointers,
>otherwise it is at least as good as C or Pascal for good coding form.

Does it have enumeration types ?
Does it have record types ? (Is this the 'structures' mentioned below ?)
Does it permit dynamic data structures ? (I know, it has no pointers, but
Prolog, Scheme, or PostScript have no explicit pointers either and still permit this).
Does it require variables to be declared before use ? (This is a major
  advantage for any non-toy program, at least in procedural programming languages).
Is there a reasonable subset of the language that runs on most implementations ?
Does it have conditional compilation directives (like #ifdef in C) ?

>There
>are even several application programs that were written in this BASIC.

People are even writing application programs in COBOL or dBase III.

>You are reading
>too much into the word BASIC.  You are taking what GWBASIC looks like and    
>most of the other old BASIC versions and assuming that all BASICS are the
>same,  they are not.

I agree. I don't know what programming language Billy Gates will be pushing in
10 years, but it certainly will be called BASIC. Now, what is the advantage of that ?

>I can write a bad program in it, but I can do that in any language.
>I expect Microsoft is basing Visual Basic on this.

Do I understand you correctly ? Microsoft thinks that if people are going to
write bad programs, they might as well write them in Visual Basic ? (Sorry,
couldn't resist :-)

>Rogerhef@Matt.ksu.ksu.edu                        Roger Heflin
>                                                 EECE Grad Student
>                                                 (913) 532-5600

Matthias

-----
Matthias Neeracher                                      neeri@iis.ethz.ch
   "These days, though, you have to be pretty technical before you can 
    even aspire to crudeness." -- William Gibson, _Johnny Mnemonic_

neeri@iis.ethz.ch (Matthias Ulrich Neeracher) (06/21/91)

In article <91171.094549F0O@psuvm.psu.edu> F0O@psuvm.psu.edu writes:
[I set the followup to alt.religion.computers, as I don't read the most
 esteemed forum comp.windows.ms.programmer]
>In article <4k4q47w164w@mantis.co.uk>, mathew@mantis.co.uk (Giving C News a
>*HUG*) says:
>>F0O@psuvm.psu.edu writes:
>>>                                     It has some nice features I wish were
>>> in Pascal or other languages.  Like QB's SELECT CASE statement; much more
>>> powerful then Pascals.
>>What, you mean it allows general boolean expressions for each CASE, like
>>Clipper 5.0 does?  That makes it just syntactic sugar; most other languages
>>have the same feature available, they just call it IF...ELSEIF...ENDIF.
>
>   Two examples should get my point across:
>
>   This segment will match strings that are exactly equal to "everything"
>the current value of AnotherString, or that fall between "nuts" and "soup"
>in alphabetical order
>
>   SELECT CASE AStringVariable
>      CASE "everything", "nuts" TO "soup", AnotherString
>      ...
>   END SELECT
>
>   This code will compare ANumericVariable for numbers between 1 and 4,
>7 to 9, 11, 13, or if ANumericVariable > MaxNumber
>
>   SELECT CASE ANumericVariable
>      CASE 1 to 4, 7 to 9, 11, 13, IS > MaxNumber
>      ...
>      CASE ELSE
>      ...
>   END SELECT

OK. Now, let's assume that we have defined a string class in C++ (The nice
thing about C++ is that you can do this. In BASIC, you can't):

String AStringVariable;
String AnotherString;
...
if (AStringVariable == "everything"	
   || (AStringVariable >= "nuts" && AStringVariable <= "soup)
   || AStringVariable == AnotherString
) {
...
}

if ((ANumericVariable >= 1 && ANumericVariable <= 4)
   || (ANumericVariable >= 7 && ANumericVariable <= 9)
   || ANumericVariable == 11
   || ANumericVariable == 13
   || ANumericVariable >  MaxNumber
} {
...
}

Why do I like the C++ version more than the BASIC one ?

- The C++ version works for all data types, the BASIC one only for numbers and Strings
- The meaning of the C++ version is more obvious (Once you have figured out what
  "&&" and "||" mean and why it's "==", not "=" :-). I had very big problems figuring
  out the meaning of your first example without reading your explanation.
- While the BASIC version clearly shows the comfortable string handling built
  into BASIC, it also points at the difficulties you're going to have as soon as
  you need something that is *not* built in. How would the above string example look
  if you wanted to compare the strings according to German string ordering
  rules and not according to ASCII ?
- BASIC has introduced an obscure, ugly, and non-portable syntax to handle some
  infrequent cases (Do you have an actual example where this generality is
  needed ?).

Matthias

-----
Matthias Neeracher                                      neeri@iis.ethz.ch
   "These days, though, you have to be pretty technical before you can 
    even aspire to crudeness." -- William Gibson, _Johnny Mnemonic_

mathew@mantis.co.uk (Giving C News a *HUG*) (06/21/91)

rogerhef@matt.ksu.ksu.edu (Roger Heflin) writes:
> In <MWM.91Jun20110422@raven.pa.dec.com> mwm@pa.dec.com (Mike (My Watch Has Wi
> >Of course, if I have to use QB commands (if it's one of the
> >pain-in-the-ass mouse/function key editors, forget it) and can't
> >configure it to my habits, then it's going to be an incredible pain to
> >use. Given the choice, I'd rather teach an editor I know about a
> >new language than teach an editor I don't know how to look like an
> >editor I do know.
> 
> Ah, a completely closed mind.

I think you're the one with the closed mind.  Or at least, if not closed then
severely blinkered.

I regularly use five different sorts of computer system, with about eight
different varieties of editor.  There is no way I'm going to go through the
painful process of learning each editor's idiosyncratic set of control keys.

So I made up my own set of control keys.  They're more systematic than just
about any others I've seen; rather than "F6 = search" or "Ctrl-K Ctrl-K =
blocK end(K)", almost all of the commands are derived from the first letters
of the words.  So "Search Forward" is ^S^F.  "File Load" is ^F^L.  Single
ctrl-key strokes are reserved for things I use all the time, like block
operations -- where ^D = Delete, ^C = Copy, ^M = Move, and so on.

If an editor can't be re-bound to use my chosen set of keyboard controls,
then I use a different editor.  Simple as that.  Life's too short to learn
control keys.

I don't use the Microsoft integrated environment because the editor keys are
crap and some of them can't be reconfigured.  My editor can call the compiler
and debugger and make and do all the other useful things the integrated
environment can do anyway, plus a lot more besides.

> The integrated enviroment that you so had acts just like the rest of the
> windows enviroment.  You bitch about those "pain-in-the-ass mouse/function
> key editors", what editor are you using that doesn't use function keys?
> Emacs, the editor with many shift keys?  That is only easier to use after
> you have spent months learing the key sequences.  I can train someone to use
> the QB editor in a day, you cannot say that for your editor.

Actually, I can.  My girlfriend was editing multiple TeX documents in an
afternoon -- using *my* key bindings and *my* TeX macros, of course.  She's
not particularly computer-literate.

I wouldn't use Emacs with the standard key bindings either.  I re-configured
it.


mathew

 

mwm@pa.dec.com (Mike (My Watch Has Windows) Meyer) (06/21/91)

In article <1991Jun21.002629.17528@maverick.ksu.ksu.edu> rogerhef@matt.ksu.ksu.edu (Roger Heflin) writes:
   In <MWM.91Jun20110422@raven.pa.dec.com> mwm@pa.dec.com (Mike (My Watch Has Windows) Meyer) writes:

   >You mean QB already understands C, C++, Pascal and ... ?

   No it doesn't understand C.. but Microsofts other integrated enviroments
   do and all of the work exactly the same, they also work the same as most
   all of the windows applications.

So I can't use the QB editor for a multilanguage project. That's a
major strike against it.

   >Of course, if I have to use QB commands (if it's one of the
   >pain-in-the-ass mouse/function key editors, forget it) and can't
   >configure it to my habits, then it's going to be an incredible pain to
   >use. Given the choice, I'd rather teach an editor I know about a
   >new language than teach an editor I don't know how to look like an
   >editor I do know.

   Ah, a completely closed mind.

Ah, a gratuitous insult. You obviously never considered that someone
might have different tastes than you do. I don't like moving my hands
from the mouse to the keyboard; any environment that requires me to
use the mouse for things other than indicating screen positions or
objects is a pain to use. Editors built around the mouse/function key
paradigm tend to have features that aren't available except through
those two devices. Function keys are slightly better than the mouse,
but don't move well from platform to platform.

   >Is QB one of those awfull "integrated environments" so loved on
   >mono-tasking environments? In general, they're just a pain, but better
   >than the alternatives. I much prefer the system I've got, where the
   >editor/compiler/debugger all run as seperate tasks and commmunicate
   >with each other via IPC. That way, I can use any editor I want, and
   >not have to worry about what other people are doing.

   The integrated enviroment that you so had acts just like the rest of the
   windows enviroment.

Ah, another strike against them. The windows interface, MS-DOS and the
8086 architechtures deserve each other.

   You bitch about those "pain-in-the-ass mouse/function
   key editors", what editor are you using that doesn't use function keys?
   Emacs, the editor with many shift keys?

Yup. I get the same interface across all the platforms I use, from
68000 boxes to Crays. If they're running X, I get a very good match on
the mouse interface. Being able to move that way is important to some
people, not to others.

   That is only easier to use after you have spent months learing the key
   sequences.  I can train someone to use the QB editor in a day, you cannot
   say that for your editor.

Yup, emacs isn't for the infrequenst user. I don't use my editor
infrequently (I probably spend more time typing at it than anything
else on the system). I don't care if I need to spend a couple of days
(that's all it took me, anyway) learning to use it nearly as much as I
care that it's fast and powerfull. Of course, I'm also bright enough
not to try insisting that anybody has to use it, or that it's right
for any particular purpose.

Based on which questions you chose to ignore, I can only conclude that
QB (and it's editor) are wired down to mice/function keys, isn't very
configurable, won't work with multiple languages, and don't support
IPC so they can be integrated with other tools.

Sounds like a pretty lame excuse for a development environment to me.

	<mike
--
Don't tell me how to live my life			Mike Meyer
Don't tell me what to do				mwm@pa.dec.com
Repression is always brought about			decwrl!mwm
by people with politics and attitudes like you.

awesley@vela.acs.oakland.edu (WESLEY ANTHONY ) (06/22/91)

rogerhef@matt.ksu.ksu.edu (Roger Heflin) writes:

>You yell about BASIC being bad.  Have you ever used Microsoft QuickBasic?

Funny this should be mentioned.  I just started doing maintenance in QB 7.1.

>It is structured and considerable easier to use than any other language.  

Chuckle.  Structured?  ABout subroutine nested N-deep?  

>The language look pretty much like any other structured language, such as
>C or Pascal, the only limitation that QB has is it does not have pointers,

This is great stuff!  Is this going to rec.humor.funny?  How do I
force QBasic to flag an undeclared variable as an error.  If I mistype
a long variable, no error message, just a new variable.  Didn't everyone
figure out this was a Bad Feature (TM) in a programming language way
back around FORTRAN-66 or so?

>otherwise it is at least as good as C or Pascal for good coding form.  

Love it!  Keep 'em coming, you're killing me!
-- 
  I switched from Dianetics to Diuretics!          Tony Wesley/RPT Software
    awesley@vela.acs.oakland.edu                     voice: (313) 274-2080
       Compu$pend: 72770,2053                         data: (313) 278-9146

rogerhef@matt.ksu.ksu.edu (Roger Heflin) (06/22/91)

In <MWM.91Jun21112437@raven.pa.dec.com> mwm@pa.dec.com (Mike (My Watch Has Windows) Meyer) writes:

>Ah, a gratuitous insult. You obviously never considered that someone
>might have different tastes than you do. I don't like moving my hands
>from the mouse to the keyboard; any environment that requires me to
>use the mouse for things other than indicating screen positions or
>objects is a pain to use. Editors built around the mouse/function key
>paradigm tend to have features that aren't available except through
>those two devices. Function keys are slightly better than the mouse,
>but don't move well from platform to platform.

I see the pot is calling the kettle black.  What you say above applies
to you just as much as it applies to me.  You started this by saying  
BASIC==BAD, you assumed that what you thought was best for everyone, if you
like it everyone must, so if you think is it bad everyone must.

All of QB mouse function commands can be worked from the keyboard using various
ctrl sequences.  But when you can't remember what the sequence is there
is always the menu.

>   The integrated enviroment that you so had acts just like the rest of the
>   windows enviroment.

>Ah, another strike against them. The windows interface, MS-DOS and the
>8086 architechtures deserve each other.

The windows enviroment works considerably easier than the X-windows enviroment,
If you hate windows so much, why bother to flame anyone discussing what you
consider a worthless. 

Why are you even putting your 2 cents worth in in a group that you just  
said discusses something worthless?

--
Rogerhef@Matt.ksu.ksu.edu                        Roger Heflin
                                                 EECE Grad Student
                                                 (913) 532-5600

rogerhef@matt.ksu.ksu.edu (Roger Heflin) (06/22/91)

In <7451@vela.acs.oakland.edu> awesley@vela.acs.oakland.edu (WESLEY ANTHONY    ) writes:

>This is great stuff!  Is this going to rec.humor.funny?  How do I
>force QBasic to flag an undeclared variable as an error.  If I mistype
>a long variable, no error message, just a new variable.  Didn't everyone
>figure out this was a Bad Feature (TM) in a programming language way
>back around FORTRAN-66 or so?

Can you find me a language that will warn you if you mistype a variable?
Without using something like lint.  C assumes you knew what you were doing.
Is QB wrong for making that assumption, at least QB doesn't let you mix
your strings and numeric variables up.  By default C has that Bad Feature
that you mentioned. 
--
Rogerhef@Matt.ksu.ksu.edu                        Roger Heflin
                                                 EECE Grad Student
                                                 (913) 532-5600

cks@hawkwind.utcs.toronto.edu (Chris Siebenmann) (06/22/91)

rogerhef@matt.ksu.ksu.edu (Roger Heflin) writes:
| Why are you even putting your 2 cents worth in in a group that you just  
| said discusses something worthless?

 Hint: crossposting to alt.religion.computers is usually taken by
bystanders as an invitation to convince people that their views are
either wrong or stupid or both. People who would rather not have the
criticism should stop cross-posting.

--
    ported program:	  a program which takes constant or increasing
			  effort to port to each new machine.
    portable program: a program which takes less effort to port to
		      each new machine.
cks@hawkwind.utcs.toronto.edu	           ...!{utgpu,utzoo,watmath}!utgpu!cks

coates@uc780.umd.edu (06/22/91)

In a previous article, rogerhef@matt.ksu.ksu.edu (Roger Heflin) wrote:
>In <7451@vela.acs.oakland.edu> awesley@vela.acs.oakland.edu (WESLEY ANTHONY
>) writes:
> 
>>This is great stuff!  Is this going to rec.humor.funny?  How do I
>>force QBasic to flag an undeclared variable as an error.  If I mistype
>>a long variable, no error message, just a new variable.  Didn't everyone
>>figure out this was a Bad Feature (TM) in a programming language way
>>back around FORTRAN-66 or so?
> 
>Can you find me a language that will warn you if you mistype a variable?
>Without using something like lint.  C assumes you knew what you were doing.
>Is QB wrong for making that assumption, at least QB doesn't let you mix
>your strings and numeric variables up.  By default C has that Bad Feature
>that you mentioned. 
>--
>Rogerhef@Matt.ksu.ksu.edu                        Roger Heflin
>                                                 EECE Grad Student
>                                                 (913) 532-5600

In MS C 5.1 with the strictest checking level you can not declare and use
an identifier simultaneously. I don't use the lower checking levels, but I'm
pretty sure you can't do it that at those levels either.
You can not simply assign an int or float to a char in C, or vice versa..
You can cast an int to a char, but you do so explicitly.
	
		ch = fgetc(file);	// gets int of character from file
		fn_buf[i] = (char)ch;	// assigns charcter to ith place in 
					// string array


**************************************************************************
*                     Elliott Coates, washington dc                      *
*                         coates@uc780.umd.edu                           *
*                             coates@uc780.bitnet                        *
**************************************************************************

kblackne@mcs.drexel.edu (Ken Blackney) (06/22/91)

Could you kids take this fight elsewhere?  Your replies make
heat, but no light.  Some of us who are reading this list for
useful information or to help others do not really care a whole
lot about your preferences in editor key bindings.

As a development language, BASIC may no have what you want.
The Visual BASIC environment may not suit your needs.  Fine.
Tell us why then let it die.

I bought Visual Basic on Monday.  I returned it Saturday.
I based my return decision on two factors: C++ is better
suited to my development needs and the Visual Basic user
interface violates my preferences (it violates sensible
design guidelines).

VB stars with a minimum of four windows on screen.  One of
these windows has a half-height caption bar with no identifing
text and a very tiny system menu bitmap.  These windows are
_not_ enclosed in a larger window (that, is, it does not act
like Word, Program Manager, or even Write).  This thingg looks
like no other apps I have seen for Windows.  (This does happen
a lot on the Macintosh, but that's another fight... :-)

The windows of other applications show through between the VB
windows.  When you activate another application then click on
a VB window, only that window comes forward; to bring the whole
application to the front requires clicking in each open window.

The "Window" menu shows names for each window.  Choosing one of
these items makes the window appear or hide.  VB never shows a
check mark next to those windows it is showing.

Maybe Microsoft did this to convince the FTC that its applica-
tions group is not only not talking to the system group, but
not even reading the documentation they put out.

(Dear Microsoft: Had anyone who worked on Visual Basic ever
seen a commercial Windows application?  Had they ever read the
documentatio?  And who is this "Cooper" company?)

If anyone wants to reply, please consider whether you want to
reply to me or to the list (and if me, reply to the address below,
not the one this was posted from).  Sorry for getting up on a
semi-high-horse.

Ken

_______________________________________________________________________________
Ken Blackney                          Voice:  (215) 895-1505
Senior Consultant                     Fax:    (215) 895-1997 or 1724
Computing Resource Group              Email: Ken_Blackney@DUPR.OCS.Drexel.EDU
Office of Computing Services          Drexel University, Philadelphia, PA 19104

dylan@ibmpcug.co.uk (Matthew Farwell) (06/23/91)

In article <1991Jun22.040758.9453@maverick.ksu.ksu.edu> rogerhef@matt.ksu.ksu.edu (Roger Heflin) writes:
>In <7451@vela.acs.oakland.edu> awesley@vela.acs.oakland.edu (WESLEY ANTHONY    ) writes:
>>This is great stuff!  Is this going to rec.humor.funny?  How do I
>>force QBasic to flag an undeclared variable as an error.  If I mistype
>>a long variable, no error message, just a new variable.  Didn't everyone
>>figure out this was a Bad Feature (TM) in a programming language way
>>back around FORTRAN-66 or so?
>Can you find me a language that will warn you if you mistype a variable?
>Without using something like lint.  C assumes you knew what you were doing.
>Is QB wrong for making that assumption, at least QB doesn't let you mix
>your strings and numeric variables up.  By default C has that Bad Feature
>that you mentioned. 

$ cat > x.c
#include <stdio.h>

int main(void)
{
	int foobar;

	fooabr = 1 ;          /* <-- notice misspelling */

	printf("%d\n", foobar);

	return 0;
}
$ gcc x.c
x.c: In function main:
x.c:7: `fooabr' undeclared (first use this function)
x.c:7: (Each undeclared identifier is reported only once
x.c:7: for each function it appears in.)

Does this count as 'assumes you know what you were doing'?

Dylan.
-- 
Matthew J Farwell: dylan@ibmpcug.co.uk || ...!uunet!ukc!ibmpcug!dylan
	But you're wrong Steve. You see, its only solitaire.

pshuang@athena.mit.edu (Ping-Shun Huang) (06/24/91)

In article <1991Jun20.034708.2816@maverick.ksu.ksu.edu> rogerhef@matt.ksu.ksu.edu (Roger Heflin) writes:

 > Does your editor also do full debugging?  QB's debugger surpasses any
 > debugger I have found on any Unix machine on relibility and usability.

[flame on] I thought this thread (and this newsgroup, for that matter)
was focused on DOS programming tools.  So bringing in UNIX isn't exactly
fair.  Heflin praises the implementation of BASIC Microsoft created for
MS-DOS called QuickBASIC, and using UNIX implementations of other
languages to devalue the worth of other languages?  Hey, there are no
decent versions of BASIC available on UNIX, either, much less good
symbolic debuggers for BASIC programs.  Does that automatically lessen
the value of QuickBASIC?  No.  Apples to oranges comparison. [flame off]

I don't wish to help fuel a language war.  I would like to point out to
those warring that what Heflin likes so much about QuickBASIC isn't
really the BASIC language itself so much as the implementation -- and
while we probably can't come to an agreement about whether BASIC is
better or worse than other languages, I think we could probably all
agree that Microsoft QuickBASIC is a darn good implementation of BASIC.

The interactiveness of the QuickBASIC environment is much superior to
UNIX in some ways, but is easily matched by the Borland IDE for Pascal
and C/C++.  Likewise debugging facilities of QuickBASIC are very good,
but Borland TP/C/C++ IDE's have excellent built-in debuggers with the
boasted browse facilities, and the capabilities of the stand-alone Turbo
Debugger is simply outstanding.  But just because these implementations
are so good does not imply that there's anything inherently superior
about Pascal/C/C++ amongst the procedural languages (or that there
isn't) -- merely that these languages are ones which a particular vendor
has invested money and development time in.

--
Above text where applicable is (c) Copyleft 1991, all rights deserved by:
UNIX:/etc/ping instantiated (Ping Huang) [INTERNET: pshuang@athena.mit.edu]

brianw@spider.co.uk (Brian Wyld) (06/24/91)

From: kblackne@mcs.drexel.edu (Ken Blackney)
>The windows of other applications show through between the VB
>windows.  When you activate another application then click on
>a VB window, only that window comes forward; to bring the whole
>application to the front requires clicking in each open window.

>The "Window" menu shows names for each window.  Choosing one of
>these items makes the window appear or hide.  VB never shows a
>check mark next to those windows it is showing.

>Maybe Microsoft did this to convince the FTC that its applica-
>tions group is not only not talking to the system group, but
>not even reading the documentation they put out.

>(Dear Microsoft: Had anyone who worked on Visual Basic ever
>seen a commercial Windows application?  Had they ever read the
>documentatio?  And who is this "Cooper" company?)

I read a review in Personal Computer World (this month's) (thats
a UK mag BTW) which said that the window app style VB uses
is a "new standard" MS kind of made up to kind of superceed
the MDI style. Mostly cause in MDI the frame can restrict the children
and so you have to scroll about.

Actually I thought that was the whole idea, but for Win 3.1 the new
VB style is "in". 

This came from the article, so I don't know how reliable it is but
PCW usually get it right.
I guess this could show the FTC that the apps group are in bed with
the system group :-).

Brian Wyld
-- 
<brianw@spider.co.uk : Spider Systems Ltd, Stanwell St, Edinburgh >
<My opinions, ok?    : 031 554 9424 : Short sigs save bandwidth   >

mathew@mantis.co.uk (Giving C News a *HUG*) (06/24/91)

rogerhef@matt.ksu.ksu.edu (Roger Heflin) writes:
> In <7451@vela.acs.oakland.edu> awesley@vela.acs.oakland.edu (WESLEY ANTHONY  
> >                                                         How do I
> >force QBasic to flag an undeclared variable as an error.  If I mistype
> >a long variable, no error message, just a new variable.  Didn't everyone
> >figure out this was a Bad Feature (TM) in a programming language way
> >back around FORTRAN-66 or so?
> 
> Can you find me a language that will warn you if you mistype a variable?

main()
{
   int mistype, i;

   mistype = 0;
   for (i=0; i<10; i++)
      {
      mitsype = i * i; // Oops, typo.
      printf("%d", mistype);
      }
}

test.c
test.c(7) : error C2065: 'mitsype' : undefined

Looks like a warning to me.  Modula-2, Pascal and C++ will warn you as well.
Lisp will detect the error at run time.  In fact, the only language I can
think of which will blithely carry on and create a new variable called
"mitsype" is BASIC.  Oh, and FORTRAN, but I try not to think of that.

> Is QB wrong for making that assumption, at least QB doesn't let you mix
> your strings and numeric variables up.

Nor do Modula-2, Pascal, Lisp, C++, LOGO...


mathew

 

mathew@mantis.co.uk (Giving C News a *HUG*) (06/24/91)

kblackne@mcs.drexel.edu (Ken Blackney) writes:
> I bought Visual Basic on Monday.  I returned it Saturday.
> I based my return decision on two factors: C++ is better
> suited to my development needs and the Visual Basic user
> interface violates my preferences (it violates sensible
> design guidelines).

This takes us back to my original point.

GEM-based BASICs on the Atari ST encouraged people to produce programs with
lots of gratuitous user-interface weirdness.  From your comments about Visual
BASIC, I am now even more confident of my original assertion that it will
cause the same thing to happen in the PC Windows community.

Perhaps the reason is that people who write BASIC don't read manuals, rather
than that BASIC is an inherently bad language.  Who cares?  It's a valid
objection to the introduction of Visual BASIC whatever the underlying reason.


mathew

 

<F0O@psuvm.psu.edu> (06/24/91)

F0O@psuvm.psu.edu writes:
> In article <4k4q47w164w@mantis.co.uk>, mathew@mantis.co.uk (Giving C News a
> *HUG*) says:
>
>    This segment will match strings that are exactly equal to "everything"
> the current value of AnotherString, or that fall between "nuts" and "soup"
> in alphabetical order
>
>    SELECT CASE AStringVariable
>       CASE "everything", "nuts" TO "soup", AnotherString
>       ...
>    END SELECT

>>That's just
>>   IF AStringVariable = "everything" OR AStringVariable = AnotherString OR
>>      (AStringVariable > "nuts" AND AStringVariable < "soup")
>>   ...
>>   ELSE
>>   ...
>>   ENDIF
>>
>>In other words, the SELECT CASE you mention is just syntactic sugar for
>>IF...ELSE...ENDIF.
>>
>>If you happen to prefer the CASE syntax, in C++ you could write yourself a
>>quick macro.  And if you want to do lots of comparisons like the one you
>>mention, you could write yourself a quick macro in C++, or a function in
>>Modula-2 or Pascal.

   True, it is window dressing.  But this window dressing takes up less
lines(which would be appreciated if you're doing ALOT of comparisons and
it looks cleaner(in my opinion).

[..]

> >>                         It is a fully structured language except for the
> >> fact you can't have nested blocks as in Pascal.
> >That's like saying it's fully object-oriented except it doesn't have
> >inheritance...
>
>    Could be, except I don't use nested blocks very often, so I don't miss
> it too much.

>>Precisely!  Because you don't have the feature, you've never used it. So you
>>don't know how useful and important it is. And then when you move up to a
>>better language, you're trapped in the BASIC mindset.

   Wrong.  I program alot in Turbo Pascal, in which I have used the
nested block feature.  Just that for the programs I write here at work,
I usually don't need that feature.

   Just want to say in closing that no language is perfect.  All have
their strengths and failings; which can differ from person to person.
Basic is fine for some things, C is great for others.  Pick the
language best suited for the task.

                                                   [Tim]

mwm@pa.dec.com (Mike (My Watch Has Windows) Meyer) (06/25/91)

In article <1991Jun22.040051.9290@maverick.ksu.ksu.edu> rogerhef@matt.ksu.ksu.edu (Roger Heflin) writes:
   In <MWM.91Jun21112437@raven.pa.dec.com> mwm@pa.dec.com (Mike (My Watch Has Windows) Meyer) writes:

   >Ah, a gratuitous insult. You obviously never considered that someone
   >might have different tastes than you do.

   I see the pot is calling the kettle black.  What you say above applies
   to you just as much as it applies to me.  You started this by saying  
   BASIC==BAD, you assumed that what you thought was best for everyone, if you
   like it everyone must, so if you think is it bad everyone must.

I advise you to wake up. I never said that BASIC was bad. Someone
started saying what a great environment QB was, so I asked questions
about that environment. The answers appear to show that it's not all
that great, so I get flamed. Oh well, this is alt.religion.computers..

I'm willing to find out if QB is a reasonable language, though. Let's
see, does it ...

	run on anything other than MS-DOS platforms?
	support some form of list or dynamic array structure?
	have associate arrays?
	have the ability to map functions across those arrays?
		and generate a list of changes?
		and select elements (ala grep)?
	let me map n-ary functions across n arrays, with all the above?
	support arrays/lists that are circular?
	have some form of lazy evaluation?
	have real macros, not the text-replacement crap C has?
	let me define new control constructs?
	have an iterator construct for user data types?
	make my data types first-class elements?
	make functions first-class elements?
	allow me to create anonymous functions at run-time?
	have both lexical and dynamic binding?
	support data abstraction?
	have inheritance?
		multiple inheritance?

Any language that doesn't support a fair percentage of those probably
isn't worth my time. If you like it, fine. Me, I've gotten used to
programming languages that support the kinds of features I listed.
Having to deal with something like C or Pascal after that is painfull,
at best. Now, is QB reasonable, or is it like C and Pascal, so that
BASIC is still 20 years behind the times.

   >Ah, another strike against them. The windows interface, MS-DOS and the
   >8086 architechtures deserve each other.

   The windows enviroment works considerably easier than the X-windows
   enviroment,

Which X-windows environment? The one that looks just like Windows?
That's an interesting statement. Or maybe you mean the Open Look
environment? Or the uwm environment? or the twm environment? Or one of
the two vtwm environments?

Of course, X-windows is pretty much worthless, anyway. It comes with a
sufficient selection of environments that I can get work done without
going cursing at the window manager at regular intervals (unlike
Windows). But saying that a window system is "better than X-windows"
like saying that an OS is "better than MS-DOS". BFD; anyone who can't
do better than those two examples should find themselves another line
of work.

   If you hate windows so much, why bother to flame anyone discussing what you
   consider a worthless. 

Pointing out that "it works just like Windows" is a strike against
something is a flame? Only if you love Windows.

   Why are you even putting your 2 cents worth in in a group that you just  
   said discusses something worthless?

Oh, alt.religion.computers isn't worthless; it's a lot more worthwhile
than comp.windows.ms.programmer. It sometimes even carries usefull
information.

	<mike
--
Tried to amend my carnivorous habits			Mike Meyer
Made it nearly seventy days				mwm@pa.dec.com
Loosing weight without speed				decwrl!mwm
Eatin' sunflower seeds

mwm@pa.dec.com (Mike (My Watch Has Windows) Meyer) (06/25/91)

In article <1991Jun22.152756.25499@mcs.drexel.edu> kblackne@mcs.drexel.edu (Ken Blackney) writes:
   Could you kids take this fight elsewhere?  Your replies make
   heat, but no light.  Some of us who are reading this list for
   useful information or to help others do not really care a whole
   lot about your preferences in editor key bindings.

This has _already_ been taken elsewhere. Look at the look at the
Newsgroups: line. It includes "alt.religion.computers". That's for
discussions about key bindings, and language wars, and the like. In
otherwords, for just what's going on.

As a service to comp.windows.ms.programmer readers (who already have
enough pain in their lives), I've added a "Followup-To:" line that
makes sure any followups are sent to alt.regligion.computers. If you
can convince other readers in your group to do the sensible thing
(unlikely, considering they probably use MS-DOS) and add the same
line, this discussion might actually all migrate out of c.w.ms.p.

Remember - it's all in fun. Even though I'm taking gratuitous shots at
you, I _am_ trying to help you (helping those less fortunate than
yourself is good for your karma). So...

:-):-):-):-):-):-):-):-):-):-):-):-):-):-):-):-):-):-):-):-):-):-):-):-):-)

Note: you really _should_ add the Followup-To: line if you're reading
this in c.s.ms.p.

	<mike
--
I know the world is flat.				Mike Meyer
Don't try tell me that it's round.			mwm@pa.dec.com
I know the world stands still.				decwrl!mwm
Don't try to make it turn around.

mwm@pa.dec.com (Mike (My Watch Has Windows) Meyer) (06/25/91)

In article <91175.151747F0O@psuvm.psu.edu> F0O@psuvm.psu.edu writes:
   F0O@psuvm.psu.edu writes:
   > In article <4k4q47w164w@mantis.co.uk>, mathew@mantis.co.uk (Giving C News a
   > *HUG*) says:
   >
   >    This segment will match strings that are exactly equal to "everything"
   > the current value of AnotherString, or that fall between "nuts" and "soup"
   > in alphabetical order
   >
   >    SELECT CASE AStringVariable
   >       CASE "everything", "nuts" TO "soup", AnotherString
   >       ...
   >    END SELECT

   >>That's just
   >>   IF AStringVariable = "everything" OR AStringVariable = AnotherString OR
   >>      (AStringVariable > "nuts" AND AStringVariable < "soup")
   >>   ...
   >>   ELSE
   >>   ...
   >>   ENDIF
   >>
   >>In other words, the SELECT CASE you mention is just syntactic sugar for
   >>IF...ELSE...ENDIF.

      True, it is window dressing.  But this window dressing takes up less
   lines(which would be appreciated if you're doing ALOT of comparisons and
   it looks cleaner(in my opinion).

Actually, it's not "just syntactic sugar"; at least if they did it
right. Can I do:

	SELECT CASE string1 + string2
		CASE "everything", "nuts" TO "soup", AnotherString
		...
	END SELECT

If it let me use expressions for the "index" expressions, then
mapping it into an elseif chain requires a scratch variable. If that
meets your criteria of "sugar", then everything is sugar on top of "if
else" and "while"; and you may not even need the while.

Of course, if it insists on keywords in UPPER CASE, that negates minor
things like getting the case statement right.

	<mike

--
So this is where the future lies			Mike Meyer
In a beer gut belly; In an open fly			mwm@pa.dec.com
Brilcreamed, acrylic, mindless boys			decwrl!mwm
Punching, kicking, making noise

enag@ifi.uio.no (Erik Naggum) (06/25/91)

Roger Heflin <rogerhef@matt.ksu.ksu.edu> writes:
|
|   Emacs, the editor with many shift keys?  That is only easier to use after
|   you have spent months learing the key sequences.  I can train someone to use
|   the QB editor in a day, you cannot say that for your editor.

Ah yes, the "every user is a novice" world view.  Tell me, what does
your user do after three months of active use of the QB "editor"?
(Yes, there are editors which are good enough to allow three months
and more of active use without killing people.)

The "easy to learn" bullshit is relevant for the complete neophytes
with zero experience and barely non-zero intelligence.  Sure, this
covers a vast amount of users for the first 30 seconds, as they stare
at a demonstration version and are about to decide what to buy.  My
experience is that most users have a working memory and are reasonable
intelligent and willing to learn.  Which means that after you have
trained someone to use QB "editor" in a day, they will be at a very
low level of competence for the rest of their life, unless a miracle
happens, or they decide to leave the user-friendly asylum.  Learning
emacs takes a while, but it's surprisingly easy to just edit your
documents on an infrequent basis, too.  You don't have to know about
"transpose-paragraph" the first day, and people don't generally write
major modes for office document support the first three weeks, either.

Can you imagine a telephone which is so easy to use that you don't
need any time learning how to use it?  Think of it, a number, access
codes, dialtones, busy tone, ringing, push buttons, tones, flash, etc,
etc, are not at all user-friendly.  It would be much better if you had
a menu on the phone on which you could select with a mouse that you
wanted to move your phone to another office, select from a menu which
person you wanted to talk to, have voice feedback, "Your party is
busy", "Your party is now being summoned to answer the phone.  Please
wait."  And instead of ringing at the other end, the phone would say
"A PC salesman from Bogus, Inc would like to speak with you, shall I
tell him to bug off and forget it?"  Now think of how many times you
use a phone.  Now think of all the incredible losers in the world who
could actually _need_ a menu-based phone.  Surely that is the way to
go.

Give me expert-friendly software, and a means to go from novice to
expert which assumes that I can think and have a working brain.

</Erik>
--
Erik Naggum             Professional Programmer            +47-2-836-863
Naggum Software             Electronic Text             <erik@naggum.no>
0118 OSLO, NORWAY       Computer Communications        <enag@ifi.uio.no>

mathew@mantis.co.uk (Giving C News a *HUG*) (06/26/91)

enag@ifi.uio.no (Erik Naggum) writes:
> Can you imagine a telephone which is so easy to use that you don't
> need any time learning how to use it?  [...]
>               Now think of all the incredible losers in the world who
> could actually _need_ a menu-based phone.

You certainly picked a bad example there.

Telephones are *incredibly* badly designed; everything from the upside-down
keypad to the stupid numeric "star 2 6 hash" commands.

There are week-long training courses for secretaries to teach them to use
their telephones, because the telephones are so appallingly badly designed.
Most businessmen have no idea how to use their telephones for even a quarter
of the things they can be used for.

I used to use a telephone with features like forward call, redial, multiple
lines, and so on; it had oodles of those little dinky calculator-style
buttons all over it, and loads of multi-coloured LEDs.  It was like Wesley's
control panel in Star Trek.

In order to make it useful, there was a one-page "Quick Reference Card",
listing all the stupid numeric codes you were supposed to remember in order
to do everyday things like tranferring calls.

I sat and looked at the card, doodled on some paper for a bit, and worked out
that you could encode just about every function supported by this telephone
into about ten or twenty buttons.  The buttons would have words on them, and
you'd indicate what you wanted to do by pushing buttons to make a sentence. 
The buttons would be arranged in columns going from left to right, so you'd
pick no more than one from each column.

Of course, it would be trickier to decode internally.  So we have telephones
with "[*] [5] [6] [#] [2] [3]" instead of "[Transfer call] [to] [2] [3]",
because it's easier for the hardware people to handle.  And we have telephones
with one button for each combination of operations, rather than a smaller set
of buttons which you can push more than one of.

It was almost enough to make me want to buy a Mac just so that I could use
Hypercard to design a proper telephone front-end and have the Mac beep the
correct tones into my bozo-phone.


mathew

 

truman@yosemite.berkeley.edu (Tom Truman) (06/26/91)

In article <MWM.91Jun24122010@raven.pa.dec.com>, mwm@pa.dec.com (Mike (My Watch Has Windows) Meyer) writes:
|> 
|> Which X-windows environment? The one that looks just like Windows?
|> That's an interesting statement. Or maybe you mean the Open Look
|> environment? Or the uwm environment? or the twm environment? Or one of
|> the two vtwm environments?
|> 
|> Of course, X-windows is pretty much worthless, anyway. It comes with a
|> sufficient selection of environments that I can get work done without
|> going cursing at the window manager at regular intervals (unlike
|> Windows). But saying that a window system is "better than X-windows"
|> like saying that an OS is "better than MS-DOS". BFD; anyone who can't
|> do better than those two examples should find themselves another line
|> of work.


What ??? Your naive description of X and the concept of multiple window
managers is boorish. 

If X is *worthless* and is a poor example of a window system, please,
let the rest of us in on a *good* one!!

mwm@pa.dec.com (Mike (My Watch Has Windows) Meyer) (06/27/91)

In article <14296@pasteur.Berkeley.EDU> truman@yosemite.berkeley.edu (Tom Truman) writes:

   If X is *worthless* and is a poor example of a window system, please,
   let the rest of us in on a *good* one!!

Check out Rob Pike's talk on 8 & 1/2 in the Summer '91 USENIX
Proceedings. While it clearly has some problems, they appear to be
minor. More importantly, the system is small enough that rewriting it
from scratch isn't something one would consider only as a last resort.

	<mike
--
Teddies good friend has his two o'clock feast		Mike Meyer
And he's making Teddies ex girl friend come		mwm@pa.dec.com
They mistook Teddies good trust				decwrl!mwm
Just for proof that Teddy was dumb.

mrs@netcom.COM (Morgan Schweers) (06/29/91)

Some time ago mathew@mantis.co.uk (Giving C News a *HUG*) happily mumbled: 
>enag@ifi.uio.no (Erik Naggum) writes:
>> Can you imagine a telephone which is so easy to use that you don't
>> need any time learning how to use it?  [...]
>>               Now think of all the incredible losers in the world who
>> could actually _need_ a menu-based phone.
>
>You certainly picked a bad example there.
>
>Telephones are *incredibly* badly designed; everything from the upside-down
>keypad to the stupid numeric "star 2 6 hash" commands.
>
>[much support for Erik's comment deleted]
Greetings,
    Heh heh heh...  So let me get this straight.  You would prefer a
mildly powerful but 100% unportable development system over a VERY
powerful and portable system.  Right?

    To clarify...  VB is, evidently, a reasonable adaptation of BASIC.
Claiming, however, that this legitimizes BASIC is like putting a powerful
engine in a VW Bug to convince people to buy VW Bugs.  All these new features
are 'bags on the side' of BASIC.  It makes it 'better', but doesn't change
the important information about the language.  (Like it's lack of pointers,
and it's lack of proper syntax checking.)

    If you do use VB as a language, you'll never be able to port your
application to another environment.  If you use C[++] as a language
you'll be able to port to *FAR* more systems, easily.  If portability
isn't an issue *AND* pointers aren't needed, then you're not likely
doing much real programming.  Either that, or you're a wee bit short-
sighted.  (There comes a time in most projects when someone says,
"Oooh!  Wouldn't it be Neat-O-Keen if we could sell this under the
XYZZY platform as well?"  Either that or, "Oh!  The LOS (Little Operating
System) isn't the Hot Thing(tm) anymore!  I guess we'll all port our
software to the BOS (Bigger Operating System)!")
    In summary, Get A Real Language!  (*heh heh heh*  I love comp.flame... I
can say things like that!)

    The person who claimed that C and Pascal wouldn't warn you about mistyped
variables made me laugh...  I love it when people rail against languages
they've clearly never used.  *grin*  C assumes that the programmer is right,
but also assumes that the programmer *CAN BE WRONG*!  If it didn't assume that
then there wouldn't be any compile-time error messages.  As someone else said,
the 'Oh!  A new variable!  No problem!' approach went out with some random
early version of Fortran.

    I'm reading this from comp.flame, so I don't want to hear about
inappropriate crossposting!

>mathew
                                                    --  Morgan Schweers

P.S.  If YOUR site doesn't get comp.flame, COMPLAIN TO YOUR ADMINISTRATOR!
-- 
mrs@netcom.com   |   Morgan Schweers   |  Good code, good food, good sex.  Is
ms@gnu.ai.mit.edu|   These messages    |  anything else important?  --  Freela
Kilroy Balore    |   are not the       +--------------------------------------
Freela           |   opinion of anyone.|  I *AM* an AI.  I'm not real...

cks@hawkwind.utcs.toronto.edu (Chris Siebenmann) (06/29/91)

truman@zion.berkeley.edu writes:
| What ??? Your naive description of X and the concept of multiple window
| managers is boorish. 
| 
| If X is *worthless* and is a poor example of a window system, please,
| let the rest of us in on a *good* one!!

 Mike Meyer has already mentioned Rob Pike's 8.5, but you should also go
read some papers on the (original) Blit. The Blit is (don't use the
past tense, there's one sitting in my other office and it works fine)
one of the first windowing interfaces to Unix, and it's a great
illustration of how to make a small simple Unix-friendly and highly
useful windowing interface. And the programming documentation fits
comfortably in a file folder (printed single-sided 1-up), which is not
something one can say about X.

--
">> And whenever it [a proposed C compiler] encounters some code whose
 >> behavior is undefined (such as fflush(stdin);) it will draw a
 >> picture of Snow White (tm) on the screen [...]
 > Quality of Implementation issues are usually resolved by the free market.
 Indeed they are.
 Geoff, when you finish writing that compiler, I want TWO of them."
		- John Woods
cks@hawkwind.utcs.toronto.edu	           ...!{utgpu,utzoo,watmath}!utgpu!cks

feustel@netcom.COM (David Feustel) (06/29/91)

I'm not sure what proper syntax checking is, but VB does some
checking.  Also, the big plus of VB is the ease of putting together
windows-interfaced applications. You can write DLLS in C++ and call
them from VB to do the computation, letting VB handle the windows.
-- 
David Feustel, 1930 Curdes Ave, Fort Wayne, IN 46805, (219) 482-9631
EMAIL: feustel@netcom.com  

I voted for Bush once.  As it's turning out, once was once too often.