Bots and Simulations > DNA - General

Inline != (Not equal to)

(1/2) > >>

Panda:
Erm. No matter how hard I try to do an inline !=, or even think about it, well, I just cannot do it. I need some help please.

peterb:

--- Quote from: Panda ---Erm. No matter how hard I try to do an inline !=, or even think about it, well, I just cannot do it. I need some help please.
--- End quote ---

you need to work with tables

for example you dont want .Amem totbe 5 and then do something

--- Code: ---*.amem -5  add  sgn abs 1   sub abs   
'       1    -4 -1    1      0      0
'       2    -3 -1    1      0      0
'       5     0  0    0     -1      1
'       7     1  1    1      0      0

--- End code ---

>>from here you got valeu 1 to multiply to do something if something equals 5   like 1 x 5 .up store
>> if you want to execute only if it isnt 5 you can do without the last 2 columns (then sgn is the last one)

ikke:
a-a add sgn mult?

Panda:

--- Quote from: ikke ---a-a add sgn mult?
--- End quote ---

I did
--- Code: ---*.var -a add sgn abs mult
--- End code ---
, I think, I may not be completely correct, though.

And thanks peterb, I didn't ever think of doing it like that .

bacillus:
You do know there's a sub command. It subtracts.

Navigation

[0] Message Index

[#] Next page

Go to full version