If Print
#12
Purebasic supports no such thing as "THEN". However every "IF" had to be matched by "ENDIF" and you weren't given the choice, even if it was to execute a single statement and if it were on one line. Like so:

Code: (Select All)
If A = "foo" : PrintN(A) : EndIf

"THEN" replaced by colon for a single-line "IF" statement, on that language which to me is more like Pascal than like BASIC.

Not sure but Texas Instruments cartridge basic allowed "THEN" replaced only by "GOTO" because the conditional statement only supported branching. This might be true about other interpreted BASIC's.

@TerryRitchie you have just depressed me, I lost my Tandy1000HX a long time ago... funnest toy I've ever had which couldn't do multimedia.

(03-03-2023, 08:15 PM)James D Jarvis Wrote: okay not completely related but does anyone recall why "?" was used as a shorthand for print?  It seems like a great shorthand for Input but baffling for print.  Is it just because "?" look a little like "P" ?

How about "P." on TRS-80 Model I? "GOS." for "GOSUB". Cryptic error messages different from "?SN ERROR" from my Color Computer 2? LOL at "hunt-and-peck", no problem for most of the users of the British computer though.

The TRS-80 Model I must have had no more than 4KB RAM but the interpreter did a poor job trying to help the programmer conserve characters in memory to hold the program. LOL just one character off "GOSUB" for its abbreviation? Anyway it's what I read about; I didn't have a computer older than a TRS-80 Model III that somebody abandoned. :/
Reply


Messages In This Thread
If Print - by Dimster - 03-03-2023, 06:33 PM
RE: If Print - by TerryRitchie - 03-03-2023, 06:45 PM
RE: If Print - by vince - 03-03-2023, 06:48 PM
RE: If Print - by Petr - 03-03-2023, 07:04 PM
RE: If Print - by CharlieJV - 03-03-2023, 07:43 PM
RE: If Print - by James D Jarvis - 03-03-2023, 08:15 PM
RE: If Print - by TerryRitchie - 03-03-2023, 09:50 PM
RE: If Print - by SMcNeill - 03-04-2023, 12:06 AM
RE: If Print - by James D Jarvis - 03-04-2023, 01:35 AM
RE: If Print - by SMcNeill - 03-04-2023, 05:07 AM
RE: If Print - by Dimster - 03-04-2023, 01:50 PM
RE: If Print - by James D Jarvis - 03-06-2023, 05:07 PM
RE: If Print - by mnrvovrfc - 03-04-2023, 02:47 PM
RE: If Print - by TerryRitchie - 03-04-2023, 06:05 PM



Users browsing this thread: 8 Guest(s)