From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: uzibalqa Newsgroups: gmane.emacs.help Subject: Re: Making a list of lists Date: Mon, 03 Jul 2023 17:51:42 +0000 Message-ID: References: <87jzvhdkkz.fsf@whxvd.name> <87v8f1c544.fsf@whxvd.name> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="6988"; mail-complaints-to="usenet@ciao.gmane.io" Cc: help-gnu-emacs@gnu.org To: Sebastian Miele Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Mon Jul 03 19:52:45 2023 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1qGNjA-0001cw-Tt for geh-help-gnu-emacs@m.gmane-mx.org; Mon, 03 Jul 2023 19:52:45 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qGNiT-0007wL-Ca; Mon, 03 Jul 2023 13:52:01 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qGNiQ-0007vV-Ag for help-gnu-emacs@gnu.org; Mon, 03 Jul 2023 13:51:58 -0400 Original-Received: from mail-4319.protonmail.ch ([185.70.43.19]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qGNiO-0008N4-45 for help-gnu-emacs@gnu.org; Mon, 03 Jul 2023 13:51:58 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=proton.me; s=protonmail; t=1688406712; x=1688665912; bh=O9B/yzPI9YjyXCsbOS3mzbVXp5DAzMhRJcSMH2/R4II=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector; b=ZQ+ar7+4deEYq1DjtcdSuPa307AhGk3e2Cz4RPm/RO82EYhUewv/SL3hwNJnKj+Sh FgUdo6RpMxF6K3zIlFcKobAEbYxdGSsoz0l3ILQEUUcJzubGATDjTNk+L+8CVUW1Sy X5mR7L4jQL8hzKREVtnTvUHMh8K2d63a1JN/16TNyZODRiEh7gPFEQTYsZIgiYSAaa r/deu9KQvjul6UrHhnc4j7ZMx8kAXaGR/80BuXG2yH5wx5xuZARdUPNGl/IspW9czy 0P7Kq9kkUEMIjSL3SDmbpjEo6jdukIgqYzpKsR8Y4pVq2b3CuGWv0VrXmqm5TbFT5i BIkePQF4KZ/7w== In-Reply-To: <87v8f1c544.fsf@whxvd.name> Feedback-ID: 52887082:user:proton Received-SPF: pass client-ip=185.70.43.19; envelope-from=uzibalqa@proton.me; helo=mail-4319.protonmail.ch X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.help:144098 Archived-At: ------- Original Message ------- On Tuesday, July 4th, 2023 at 4:44 AM, Sebastian Miele wr= ote: > > From: uzibalqa uzibalqa@proton.me > > Date: Mon, 2023-07-03 16:41 +0000 > >=20 > > Suppose I have mylist, with a number of lists constructed as follows > >=20 > > (setq mylist '()) > > (setq entry1 (linseq "A" "B" "C")) > > (setq entry2 (linseq "D" "E" "F")) > >=20 > > Then how do I add entry1 and entry2, to mylist ? >=20 >=20 > Examples: >=20 > (setq mylist (cons entry1 (cons entry2 mylist))) > (push entry2 mylist) (push entry1 mylist) > (add-to-list 'mylist entry2) (add-to-list 'mylist entry1) > (setq mylist `(,entry1 ,entry2 ,@mylist)) Can push be used with multiple entries ?=20 (push entry1 entry2 mylist) I would like to write a function that pushes a whole list to a list, to mak= e a list of lists, called a chart. Here is my function, but need some form of loop, to traverse all the functi= on arguments. (defun linseq (&rest sequence) sequence) (defun attach (chart &rest linsq) (apply #'push linsq chart)) =20