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


Groups > comp.lang.forth > #132416

Re: Reverse SCAN SPLIT

From dxf <dxforth@gmail.com>
Newsgroups comp.lang.forth
Subject Re: Reverse SCAN SPLIT
Date 2024-10-07 22:22 +1100
Organization i2pn2 (i2pn.org)
Message-ID <8195b3d00499f82168a805aaa3a0be86097a0cc4@i2pn2.org> (permalink)
References <5c65a8f1fdfc3e9937a825842fe23dc2758f48ef@i2pn2.org> <ve0bit$1lo0q$1@dont-email.me>

Show all headers | View raw


On 7/10/2024 9:02 pm, Ruvim wrote:
> ... 
> Why do you prefer the order ( u.hour u.min u.sec ) rather than ( u.sec u.min u.hour ) ?
> 
> The later order makes code simpler in (1) and (2), also, it follows the order of parameters in `TIME&DATE`.
> 
> Moreover, if you want to convert three components to seconds, you need to reverse their order again:
> 
> : time3-to-seconds ( u.hour u.min u.sec -- u.sec-total )
>   swap rot  60 * + 60 * +
> ;
> 
> If the order of parameters is reversed, the above definition takes a simpler form:
> 
> : time3-to-seconds ( u.sec u.min u.hour -- u.sec-total )
>   60 * + 60 * +
> ;

I thought it would be easier to convert to total secs (on 16-bit it has to be a double).
But perhaps not.

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


Thread

Reverse SCAN SPLIT dxf <dxforth@gmail.com> - 2024-10-07 19:52 +1100
  Re: Reverse SCAN SPLIT melahi_ahmed@yahoo.fr (Ahmed) - 2024-10-07 09:55 +0000
    Re: Reverse SCAN SPLIT melahi_ahmed@yahoo.fr (Ahmed) - 2024-10-07 10:03 +0000
      Re: Reverse SCAN SPLIT dxf <dxforth@gmail.com> - 2024-10-07 23:07 +1100
        Re: Reverse SCAN SPLIT melahi_ahmed@yahoo.fr (Ahmed) - 2024-10-07 19:25 +0000
          Re: Reverse SCAN SPLIT dxf <dxforth@gmail.com> - 2024-10-08 13:58 +1100
            Re: Reverse SCAN SPLIT melahi_ahmed@yahoo.fr (Ahmed) - 2024-10-08 06:02 +0000
  Re: Reverse SCAN SPLIT Ruvim <ruvim.pinka@gmail.com> - 2024-10-07 14:02 +0400
    Re: Reverse SCAN SPLIT dxf <dxforth@gmail.com> - 2024-10-07 22:22 +1100
  Re: Reverse SCAN SPLIT dxf <dxforth@gmail.com> - 2024-10-07 23:13 +1100
  Re: Reverse SCAN SPLIT dxf <dxforth@gmail.com> - 2024-10-10 17:00 +1100
  Re: Reverse SCAN SPLIT albert@spenarnc.xs4all.nl - 2024-10-10 10:00 +0200
    Re: Reverse SCAN SPLIT dxf <dxforth@gmail.com> - 2024-10-10 20:57 +1100
      Re: Reverse SCAN SPLIT Hans Bezemer <the.beez.speaks@gmail.com> - 2024-10-16 18:13 +0200
        Re: Reverse SCAN SPLIT albert@spenarnc.xs4all.nl - 2024-10-17 10:28 +0200
          Re: Reverse SCAN SPLIT minforth@gmx.net (minforth) - 2024-10-17 09:16 +0000
          Re: Reverse SCAN SPLIT mhx@iae.nl (mhx) - 2024-10-17 10:29 +0000
            Re: Reverse SCAN SPLIT albert@spenarnc.xs4all.nl - 2024-10-17 12:48 +0200
              Re: Reverse SCAN SPLIT dxf <dxforth@gmail.com> - 2024-10-19 01:41 +1100
                Re: Reverse SCAN SPLIT albert@spenarnc.xs4all.nl - 2024-10-19 13:36 +0200
            Re: Reverse SCAN SPLIT dxf <dxforth@gmail.com> - 2024-10-18 12:10 +1100

csiph-web