Author Topic: Inline != (Not equal to)  (Read 4493 times)

Offline Panda

  • Global Moderator
  • Bot Destroyer
  • *****
  • Posts: 476
  • Computer Science Undergraduate (nerd)
    • View Profile
Inline != (Not equal to)
« on: May 28, 2010, 05:38:39 AM »
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.

Offline peterb

  • Bot Destroyer
  • ***
  • Posts: 148
    • View Profile
Inline != (Not equal to)
« Reply #1 on: May 28, 2010, 09:55:46 AM »
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.

you need to work with tables

for example you dont want .Amem totbe 5 and then do something
Code: [Select]
*.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

>>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)
« Last Edit: December 22, 2011, 12:13:13 PM by Shasta »

Offline ikke

  • Bot Destroyer
  • ***
  • Posts: 300
    • View Profile
Inline != (Not equal to)
« Reply #2 on: May 28, 2010, 10:47:26 AM »
a-a add sgn mult?

Offline Panda

  • Global Moderator
  • Bot Destroyer
  • *****
  • Posts: 476
  • Computer Science Undergraduate (nerd)
    • View Profile
Inline != (Not equal to)
« Reply #3 on: May 28, 2010, 06:36:14 PM »
Quote from: ikke
a-a add sgn mult?

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

And thanks peterb, I didn't ever think of doing it like that .
« Last Edit: May 28, 2010, 06:37:12 PM by Panda »

Offline bacillus

  • Bot Overlord
  • ****
  • Posts: 907
    • View Profile
Inline != (Not equal to)
« Reply #4 on: May 29, 2010, 01:18:21 AM »
You do know there's a sub command. It subtracts.
"They laughed at Columbus, they laughed at Fulton, they laughed at the Wright brothers. But they also laughed at Bozo the Clown."
- Carl Sagan

Offline Panda

  • Global Moderator
  • Bot Destroyer
  • *****
  • Posts: 476
  • Computer Science Undergraduate (nerd)
    • View Profile
Inline != (Not equal to)
« Reply #5 on: May 29, 2010, 06:40:27 AM »
Quote from: bacillus
You do know there's a sub command. It subtracts.

If I understand what you are saying. Then yeah, I know, "-x add" is a subtraction. I could have done "x sub" but I continued doing what the other person was doing.