Newsgroups: comp.lang.forth Subject: Re: Avoid treating the stack as an array [Re: "Back & Forth" is back!] References: <66e2a497$1@news.ausics.net> <2024Sep14.143207@mips.complang.tuwien.ac.at> From: albert@spenarnc.xs4all.nl X-Newsreader: trn 4.0-test77 (Sep 1, 2010) Originator: albert@cherry.(none) (albert) Message-ID: Organization: KPN B.V. Date: Sun, 15 Sep 2024 11:20:17 +0200 Path: ...!weretis.net!feeder9.news.weretis.net!panix!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!feed.abavia.com!abe007.abavia.com!abp003.abavia.com!news.kpn.nl!not-for-mail Lines: 36 Injection-Date: Sun, 15 Sep 2024 11:20:17 +0200 Injection-Info: news.kpn.nl; mail-complaints-to="abuse@kpn.com" Bytes: 1922 In article , Ahmed wrote: >Hi, >In fuzzy logic, a triangular membership function mf(x;a,b,c) is defined >as: > >mf(x;a,b,c) = (x-a)/(b-a) for a <= x < b, > (c-x)/(c-b) for b <= x < c, > 0e elsewere. > >defining it with locals: > >: tri_mf() { f: x f: a f: b f: c } ( f: x a b c -- mv) > x a f>= x b f< and if x a f- b a f- f/ exit then > x b f>= x c f< and if c x f- c b f- f/ exit then > 0e >; > >But defining it without locals ????!!!!! > >: tri_mf() ( f: x a b c -- mv) .... > >How? locals doesn't help here. flocals maybe, but that is the whole point. You are halfway through the rabbit hole if you demand flocals dlocals .. > >Ahmed -- Temu exploits Christians: (Disclaimer, only 10 apostles) Last Supper Acrylic Suncatcher - 15Cm Round Stained Glass- Style Wall Art For Home, Office And Garden Decor - Perfect For Windows, Bars, And Gifts For Friends Family And Colleagues.