Rocksolid Light

Welcome to RetroBBS

mail  files  register  newsreader  groups  login

Message-ID:  

<Overfiend> Joy: Hey, I'm an asshole. Assholes emit odious gas. That's what we do.


devel / comp.lang.scheme / Re: (list-ref list k) ------- ( 0-index awkwardness)

SubjectAuthor
* (list-ref list k) ------- ( 0-index awkwardness)Hen Hanna
`* Re: (list-ref list k) ------- ( 0-index awkwardness)David Duffy
 `- Re: (list-ref list k) ------- ( 0-index awkwardness)Hen Hanna

1
(list-ref list k) ------- ( 0-index awkwardness)

<2a80fb80-f87d-4b70-8cbc-1eb9badc4a93n@googlegroups.com>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=164&group=comp.lang.scheme#164

  copy link   Newsgroups: comp.lang.scheme
X-Received: by 2002:a05:6214:2022:b0:497:2c03:61 with SMTP id 2-20020a056214202200b004972c030061mr2016780qvf.11.1661443297502;
Thu, 25 Aug 2022 09:01:37 -0700 (PDT)
X-Received: by 2002:a05:6902:100b:b0:695:bd4e:95d6 with SMTP id
w11-20020a056902100b00b00695bd4e95d6mr4043857ybt.595.1661443297235; Thu, 25
Aug 2022 09:01:37 -0700 (PDT)
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!feed1.usenet.blueworldhosting.com!peer02.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.lang.scheme
Date: Thu, 25 Aug 2022 09:01:36 -0700 (PDT)
Injection-Info: google-groups.googlegroups.com; posting-host=2601:648:8600:c910:0:0:0:637b;
posting-account=YjTkGAoAAAA4_fbAISfvtIqrYbghMeBx
NNTP-Posting-Host: 2601:648:8600:c910:0:0:0:637b
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <2a80fb80-f87d-4b70-8cbc-1eb9badc4a93n@googlegroups.com>
Subject: (list-ref list k) ------- ( 0-index awkwardness)
From: henhanna@gmail.com (Hen Hanna)
Injection-Date: Thu, 25 Aug 2022 16:01:37 +0000
Content-Type: text/plain; charset="UTF-8"
X-Received-Bytes: 1962
 by: Hen Hanna - Thu, 25 Aug 2022 16:01 UTC

(list-ref list k) ------- ( 0-index awkwardness) , R7RS

(i guess this problem is the same with Common Lisp's Nth and Elt.)

in the following code ,
--- Print the 10th element (in the list),
--- Print the 20th element,
--- Print the 30th element,
--- Print the 40th element,
--- Print the 50th element

came out a bit awkward.... How do ppl usually deal with it ?

________________
(define (print x) (write x) (newline))

(define a '(1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50))

(print a) (print (length a))
(print (list-ref a 9))
(print (list-ref a 19))
(print (list-ref a 29))
(print (list-ref a 39))
(print (list-ref a 49))

Re: (list-ref list k) ------- ( 0-index awkwardness)

<te90f7$eug$1@gioia.aioe.org>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=165&group=comp.lang.scheme#165

  copy link   Newsgroups: comp.lang.scheme
Path: i2pn2.org!i2pn.org!aioe.org!vkIuuldYX8RKILD6jqwd3Q.user.46.165.242.75.POSTED!not-for-mail
From: davidd02@tpg.com.au (David Duffy)
Newsgroups: comp.lang.scheme
Subject: Re: (list-ref list k) ------- ( 0-index awkwardness)
Date: Thu, 25 Aug 2022 23:26:33 -0000 (UTC)
Organization: Aioe.org NNTP Server
Message-ID: <te90f7$eug$1@gioia.aioe.org>
References: <2a80fb80-f87d-4b70-8cbc-1eb9badc4a93n@googlegroups.com>
Injection-Info: gioia.aioe.org; logging-data="15312"; posting-host="vkIuuldYX8RKILD6jqwd3Q.user.gioia.aioe.org"; mail-complaints-to="abuse@aioe.org";
User-Agent: tin/2.6.2-20220130 ("Convalmore") (Linux/5.15.0-46-generic (x86_64))
X-Notice: Filtered by postfilter v. 0.9.2
 by: David Duffy - Thu, 25 Aug 2022 23:26 UTC

Hen Hanna <henhanna@gmail.com> wrote:
> (list-ref list k) ------- ( 0-index awkwardness) , R7RS
> (i guess this problem is the same with Common Lisp's Nth and Elt.)
> in the following code ,
> --- Print the 10th element (in the list),
> --- Print the 20th element,
see Xlispstat list-select and Lisp-Stat select (and iota).

Re: (list-ref list k) ------- ( 0-index awkwardness)

<f1b3ceba-f0fd-41c6-b4a8-b2324ed446a6n@googlegroups.com>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=167&group=comp.lang.scheme#167

  copy link   Newsgroups: comp.lang.scheme
X-Received: by 2002:a05:6214:2aa6:b0:474:844b:24ff with SMTP id js6-20020a0562142aa600b00474844b24ffmr4256312qvb.51.1662574191043;
Wed, 07 Sep 2022 11:09:51 -0700 (PDT)
X-Received: by 2002:a25:7609:0:b0:69b:2d9a:4714 with SMTP id
r9-20020a257609000000b0069b2d9a4714mr4056003ybc.556.1662574190677; Wed, 07
Sep 2022 11:09:50 -0700 (PDT)
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!feed1.usenet.blueworldhosting.com!peer02.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.lang.scheme
Date: Wed, 7 Sep 2022 11:09:50 -0700 (PDT)
In-Reply-To: <te90f7$eug$1@gioia.aioe.org>
Injection-Info: google-groups.googlegroups.com; posting-host=2601:648:8600:4980:0:0:0:4873;
posting-account=YjTkGAoAAAA4_fbAISfvtIqrYbghMeBx
NNTP-Posting-Host: 2601:648:8600:4980:0:0:0:4873
References: <2a80fb80-f87d-4b70-8cbc-1eb9badc4a93n@googlegroups.com> <te90f7$eug$1@gioia.aioe.org>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <f1b3ceba-f0fd-41c6-b4a8-b2324ed446a6n@googlegroups.com>
Subject: Re: (list-ref list k) ------- ( 0-index awkwardness)
From: henhanna@gmail.com (Hen Hanna)
Injection-Date: Wed, 07 Sep 2022 18:09:51 +0000
Content-Type: text/plain; charset="UTF-8"
X-Received-Bytes: 1808
 by: Hen Hanna - Wed, 7 Sep 2022 18:09 UTC

On Thursday, August 25, 2022 at 4:26:38 PM UTC-7, David Duffy wrote:
> Hen Hanna <henh...@gmail.com> wrote:
> > (list-ref list k) ------- ( 0-index awkwardness) , R7RS
> > (i guess this problem is the same with Common Lisp's Nth and Elt.)
> > in the following code ,
> > --- Print the 10th element (in the list),
> > --- Print the 20th element,

> see Xlispstat list-select and Lisp-Stat select (and iota).

thanks.... i often don't use Iota because it's not in R7RS proper

https://quickref.common-lisp.net/lisp-stat.html

Lisp-Stat seems to be a library for Common Lisp

1
server_pubkey.txt

rocksolid light 0.9.8
clearnet tor