Previous topic - Next topic


=> ist Syntyx error und man muß >= schreiben.
Das läßt sich doch bestimmt einfach erweitern.

Wenn ich z.B. gucken möchte ob die Mauspos. in einem Rechteck ist schreibe ich immer mx=>x1
weil = der Rand ist und es dann nach innen mit > weiter geht.
Auf der rechten Seite schreibe ich mx<=x2
Die XY Koordinaten gehen ja auch von links nach rechts und oben nach unten.


In *all* programmig languages the comparation operators used are: <=, = and >=, the equal sign is always in the right. The forms => or =< are not valid. Using a=>b is odd. It's easy to put it in the correct form: b<=a.


i think not all but.
glbasic can translate it also before compiling the c source.

= and > is two in one , a human need no order , its equal or greater , greater or equal.

Visual Basic 2010 and VisualBasic 6 replace the two chars on the fly in the editor.
BlitzBasic3D understand =>
BlitzMax understand =>
DarkBasic Pro understand =>

you can see in 5 of 5 i can write it and its a entrenched habit :-)


We say "greater than or equal to" and we also say "less than or equal to". We don't tend to say it the other way around. So for me it makes sense.
http://www.spicypixel.net | http://www.facebook.com/SpicyPixel.NET

Comps Owned - ZX.81, ZX.48K, ZX.128K+2, Vic20, C64, Atari-ST, A500.600.1200, PC, Apple Mini-Mac.


the x coord move from left to right so the equal comes first then the greater.
i transfer what i see in a program.
for me is this => inside <=
it looks like two arrows , you can better read and understand this as >= <=

Ian Price

I used to use Div Games Studio and that accepted => or >=  and <= or =<

Like you Markus, I always used => and <= too, as they looked like arrows and somehow appeared neater/tidier in the code. Strange but true.

Even after using GLB for a couple of years, I still get the order wrong sometimes for comparisons like this.
I came. I saw. I played.


While on this subject I keep typing != as I am used to writing in C, If the alternatives get added could this be added as well?


i found a new example why i write this  :S

IF LEN(self.text$)=>1 THEN ...


Since I do more PHP than anything else at the moment, I would be so confused. => is used for totally different things, see snip below:

Code (glbasic) Select
$var = array(
    'first' => 1,
    'second' => 2,
    'third' => 3,

When I started programming there was languages that accepted them in any order and that just made me confused. If I would have been forced to the correct order directly mabe it would have been easier now.


PHP is gay :-)
can be much easier
the $ must confuse you also ;-)