From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Rusi Newsgroups: gmane.emacs.help Subject: Re: plists, alists, and hashtables Date: Wed, 5 Aug 2015 05:20:10 -0700 (PDT) Message-ID: References: <876150vwaa.fsf@mbork.pl> <873803x5q4.fsf@kuiper.lan.informatimago.com> <87a8u7we9s.fsf_-_@lifelogs.com> <02f81836-554f-4bb4-873b-85c24e080e3d@googlegroups.com> <87614uqn5l.fsf@kuiper.lan.informatimago.com> <87d1z2ukw1.fsf@lifelogs.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1438777233 12179 80.91.229.3 (5 Aug 2015 12:20:33 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 5 Aug 2015 12:20:33 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Aug 05 14:20:33 2015 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1ZMxgO-0007Ii-RW for geh-help-gnu-emacs@m.gmane.org; Wed, 05 Aug 2015 14:20:32 +0200 Original-Received: from localhost ([::1]:40312 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZMxgN-0008Cm-42 for geh-help-gnu-emacs@m.gmane.org; Wed, 05 Aug 2015 08:20:31 -0400 X-Received: by 10.50.50.144 with SMTP id c16mr7148731igo.11.1438777211649; Wed, 05 Aug 2015 05:20:11 -0700 (PDT) X-Received: by 10.50.141.165 with SMTP id rp5mr407061igb.2.1438777211627; Wed, 05 Aug 2015 05:20:11 -0700 (PDT) Original-Path: usenet.stanford.edu!pg9no7256235igb.0!news-out.google.com!nt1ni161igb.0!nntp.google.com!pg9no7256232igb.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help In-Reply-To: <87d1z2ukw1.fsf@lifelogs.com> Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=117.195.45.198; posting-account=mBpa7woAAAAGLEWUUKpmbxm-Quu5D8ui Original-NNTP-Posting-Host: 117.195.45.198 User-Agent: G2/1.0 Injection-Date: Wed, 05 Aug 2015 12:20:11 +0000 Original-Xref: usenet.stanford.edu gnu.emacs.help:213964 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 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.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:106249 Archived-At: On Wednesday, August 5, 2015 at 3:17:44 PM UTC+5:30, Ted Zlatanov wrote: > On Wed, 05 Aug 2015 08:12:22 +0200 "Pascal J. Bourguignon" wrote:=20 >=20 > PJB> What you are losing from sight is the fact that: >=20 > PJB> - a-lists are lists > PJB> - p-lists are lists > PJB> - lists are sequences And lists (if you were to think mathematically) are sequences And sequences are maps; in more detail: A finite sequence over =CF=84 =F0=9D=92=AE(=CF=84) is a function {1..n} = =E2=86=92 =CF=84 An infinite sequence over =CF=84 =F0=9D=92=AE(=CF=84) is a function =E2=84= =95 =E2=86=92 =CF=84 On the other side, a hash-table is just a map from keys to values (with algorithmic/storage-layout mixed up as is usually done by low-level programmers) In short a map is the fundamental data structure. Alternate Existence Proof: Lua has only one data structure -- the table -- = which does the job of both lists and hashes