Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.forth > #25107

Re: Dice problem

From Paul Rubin <no.email@nospam.invalid>
Newsgroups comp.lang.forth
Subject Re: Dice problem
Date 2013-08-11 16:42 -0700
Organization Nightsong/Fort GNOX
Message-ID <7xmwon23r3.fsf@ruckus.brouhaha.com> (permalink)
References <kp7g25$7mj$1@dont-email.me> <7xsiyf247s.fsf@ruckus.brouhaha.com>

Show all headers | View raw


Paul Rubin <no.email@nospam.invalid> writes:
> : triple ( v n -- n )  tuck count? 3 >= ( n v flag )
>     if swap -3 swap count+! else 2drop 0 then ;    

Cleanup from half-completed refactoring:

    : triple ( v n -- n )  dup count? 3 >= ( v n flag )
        if -3 swap count+! else 2drop 0 then ;

Back to comp.lang.forth | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Dice problem "WJ" <w_a_x_man@yahoo.com> - 2013-06-11 15:34 +0000
  Re: Dice problem Ron Aaron <rambamist@gmail.com> - 2013-06-11 20:04 +0300
  Re: Dice problem november.nihal@gmail.com - 2013-08-11 05:11 -0700
  Re: Dice problem Paul Rubin <no.email@nospam.invalid> - 2013-08-11 16:32 -0700
    Re: Dice problem Paul Rubin <no.email@nospam.invalid> - 2013-08-11 16:42 -0700
    Re: Dice problem Coos Haak <chforth@hccnet.nl> - 2013-08-12 02:25 +0200
      Re: Dice problem Paul Rubin <no.email@nospam.invalid> - 2013-08-11 18:02 -0700
      Re: Dice problem Paul Rubin <no.email@nospam.invalid> - 2013-08-11 23:58 -0700
  Re: Dice problem hughaguilar96@yahoo.com - 2013-08-12 00:13 -0700

csiph-web