Script Library: 1241 scripts
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

Discussion posts for script associate.r

1
brianwisti
3-Jan-2005 21:25
Silly question. Does this create something similar to an associative array (or 'hash' as the Perl world calls them)?
2
sunanda
3-Jan-2005 22:55

I think so. Here's some tricks with associate -- decide for yourself :-)

myAA: copy [] ;; start a new associative array

associate myAA 'today now

associate myAA 'myname 'Sunanda

associate myAA 'my age 21 ;; It was once. Then again later in hex.....

associate myAA 1-jan-2000 {new millennium}

associate myAA 15 [4 5 6] [1 2 3 4 5] ;; ways to sum 15 as consecutive integers

;; read some of them back:

associate? myAA 15

== [4 5 6] [1 2 3 4 5]

associate? myAA 'today

== 3-Jan-2005/22:17:39 ;; well, it was when I did it -- it's a static value

;; let's get a date that really does update itself:

associate myAA 'today [(now)]

compose associate? myAA 'today

;; result will change each time

;; being just a rebol block, I can write it to a file, and reload it later

write %myAA-file mold myAA

myAA: none ;; to prove it's gone

myAA: load %myAA-file

associate? myAA 15

== [4 5 6] [1 2 3 4 5] ;; same values as before

I could add the whole thing to another associate array

my-other-AA: copy []

associate my-other-AA 'AA1 myAA

;; I could even add it to itself:

associate myAA 'myAA myAA

3
sumnerzzupa
24-May-2021 3:56
REBOL

Neve encountered this before, but it seems good already.

Contents:

Placerville Dentistry

MakeDoc2 by REBOL- 24-May-2021
4
konstantinak
30-Aug-2021 5:35

South Korea has opened a new programming club at Soongsil University. Only a few students are allowed to attend the lectures of the famous US and UK professors who do these cheap writings https://domyassignment.pro/for an associate degree.

5
mark214
20-Nov-2021 20:29
REBOL

Great Post. Love it. landscaping in fresno

Contents:

MakeDoc2 by REBOL- 20-Nov-2021
6
marosol
10-Dec-2021 0:37
REBOL

Maybe you can.

Contents:

roofing milwaukee

MakeDoc2 by REBOL- 10-Dec-2021
7
crutcherhuyn
1-Mar-2022 17:39
8
saruonhosari
10-Mar-2022 4:47
REBOL

Being just a rebol block, I can write it to a file, and reload it later.

Contents:

mobile detailing

MakeDoc2 by REBOL- 10-Mar-2022
9
marie
16-Mar-2022 8:43
REBOL

Wow the article you give us is amazing, no wonder many people want to read this.

Contents:

drywall repair in Sacramento, CA

MakeDoc2 by REBOL- 16-Mar-2022
10
danielperez1
28-Mar-2022 5:53
REBOL

Ohh! this is so informative. Keep it up Hospitality Technology

Contents:

MakeDoc2 by REBOL- 28-Mar-2022
11
patricia
12-Apr-2022 10:47
REBOL

Thanks for sharing this informative site. washer and dryer repair nyc

Contents:

MakeDoc2 by REBOL- 12-Apr-2022
12
patricia
24-Jun-2022 5:45
REBOL

Glad to visit this again. Best regards from Tucson fence companies

Contents:

MakeDoc2 by REBOL- 24-Jun-2022
13
darrenbailey
25-Jun-2022 14:10
I don’t trust other people's opinions, but the practice shows that 
the majority of reviews can reveal the true picture. Thus, when I 
need to learn more about a service I go to specialized platforms. 
And paymetodoyourhomework reddit has become the most suitable option 
when it comes to writing services. 
https://www.writingpapersucks.com/paymetodoyourhomework-review/
14
patricia
5-Jul-2022 7:25
REBOL

Untitled

Contents:

MakeDoc2 by REBOL- 5-Jul-2022
15
ampva301
7-Jul-2022 21:50

Wow, the post you provide is incredible; no wonder so many people want to read it.

https://www.drywallmarietta.com

16
rickluck90
20-Jul-2022 21:03
This topic is very nice. I really like such fantastic information. I will keep coming here again and again. Visit my link as well. Reparacion Tejados Zamora 
17
breana
21-Jul-2022 8:37
REBOL

Great post! Thanks for this great share. roofers reno nevada

Contents:

MakeDoc2 by REBOL- 21-Jul-2022
18
janwil
21-Jul-2022 9:42
REBOL

This is awesome! Glad to know this interesting info. personal detective bristol tn

Contents:

MakeDoc2 by REBOL- 21-Jul-2022
19
miyaka22
22-Jul-2022 6:31
REBOL

Carmichael Fencing Company is a fence company in Sacramento, California, that specializes in fencing installation & fence contractor services for both residential and commercial customers.

Contents:

Wrought Iron Fence

MakeDoc2 by REBOL- 22-Jul-2022
20
richardsjenk
17-Aug-2022 0:46
REBOL

We can provide full semi trick air brake service for any problem you might be having with mobile truck suspensions, from broken springs to worn shocks.

Contents:

Semi Truck Engine Repair kansas city

MakeDoc2 by REBOL- 17-Aug-2022
21
mandiripinja
5-Dec-2022 7:52

pinjaman dana jaminan bpkb mobil cepat hanya 1 hari bisa langsung cair dengan suku bunga rendah serta tanpa survey dan bpkb mobil aman untuk seluruh wilayah indonesia.

https://www.justgiving.com/fundraising/mandiripinjamandana

https://ameblo.jp/mandiripinjamandana/entry-12680765607.html

https://ameblo.jp/mandiripinjamandana/entry-12680767540.html

https://ameblo.jp/mandiripinjamandana/entry-12680769727.html

https://ameblo.jp/mandiripinjamandana/entry-12680770493.html

https://ameblo.jp/mandiripinjamandana/entry-12680771364.html

https://ameblo.jp/mandiripinjamandana/entry-12680785558.html

https://ameblo.jp/mandiripinjamandana/entry-12680786359.html

https://ameblo.jp/mandiripinjamandana/entry-12680787122.html

https://ameblo.jp/mandiripinjamandana/entry-12680787855.html

https://ameblo.jp/mandiripinjamandana/entry-12680788647.html

https://ameblo.jp/mandiripinjamandana/entry-12680789550.html

https://ameblo.jp/mandiripinjamandana/entry-12680790188.html

https://ameblo.jp/mandiripinjamandana/entry-12680790735.html

https://ameblo.jp/mandiripinjamandana/entry-12680791419.html

https://ameblo.jp/mandiripinjamandana/entry-12680792163.html

https://ameblo.jp/mandiripinjamandana/entry-12680792608.html

https://ameblo.jp/mandiripinjamandana/entry-12680793459.html

https://ameblo.jp/mandiripinjamandana/entry-12680793916.html

https://ameblo.jp/mandiripinjamandana/entry-12680794272.html

https://ameblo.jp/mandiripinjamandana/entry-12680794619.html

https://ameblo.jp/mandiripinjamandana/entry-12680794959.html

https://ameblo.jp/mandiripinjamandana/entry-12680795284.html

https://ameblo.jp/mandiripinjamandana/entry-12680795637.html

22
crutcherhuyn
20-Dec-2022 22:48
REBOL

we offer competitive rates so that you can choose us with confidence knowing that you’re getting the best deal.

Contents:

https://billingstruckrepair.com

MakeDoc2 by REBOL- 20-Dec-2022
23
emmausa
14-Feb-2023 0:02

I'm happy that I came across this great information because this is one of the best things I've ever read. https://contextogame.co

24
joeanderson
21-Feb-2023 19:03
REBOL

Wow. That was an awesome trick!

Contents:

Joe is asking how to texture drywall. Please let me know your insights.

MakeDoc2 by REBOL- 21-Feb-2023
25
johnsjvi95
13-Mar-2023 7:11
REBOL

If you require dependable and timely auto repair services in Sacramento County, reach out to us!

Contents:

Lehi Towing Company

MakeDoc2 by REBOL- 13-Mar-2023
26
crutcherhuyn
13-Mar-2023 17:42
REBOL

When she doesn’t, you may need suspension service. That’s where we come in.

Contents:

Hattiesburg On-Site Truck Repair

MakeDoc2 by REBOL- 13-Mar-2023
27
marie
10-May-2023 23:18
REBOL

No, the previous response does not create an associative array or hash. It provides suggestions and recommendations for skandinavisches Geschenk (Scandinavian gift) ideas. It does not involve any programming or data structure operations.

Contents:

tree service Davenport IA

MakeDoc2 by REBOL- 10-May-2023
28
ampva301
16-Jun-2023 18:52
REBOL

No, your question is not silly at all! In fact, it's a great question. Yes, the concept you're referring to, an associative array or a hash, does exist in many programming languages, including Perl.

Contents:

Click herefor more info!

MakeDoc2 by REBOL- 16-Jun-2023
29
marie
14-Jul-2023 1:58
REBOL

Being just a rebol block, I can write it to a file, and reload it later.

Contents:

hardwood repairs

MakeDoc2 by REBOL- 14-Jul-2023
30
michsullivan
25-Jul-2023 9:38
REBOL

I never thought of it this way, but now I see the issue from a different angle. Thanks for broadening my perspective. roofing contractors port charlotte

Contents:

MakeDoc2 by REBOL- 25-Jul-2023
31
ampva301
10-Aug-2023 19:43
REBOL

es, the concept you're referring to is quite similar to an associative array or a 'hash' in the Perl programming world.

Contents:

Looking for stamped concretecontractors?

MakeDoc2 by REBOL- 10-Aug-2023
32
miyaka22
8-Sep-2023 10:30
REBOL

For decades, concrete has been used to construct roads, foundations, floors, and walkways. It is a strong, incredibly resilient, and lasting material.

Contents:

emergency tree removal near me

MakeDoc2 by REBOL- 8-Sep-2023
33
lindamartn15
22-Sep-2023 13:00
REBOL

There are positively a couple extra fine points to obtain hooked on consideration, nevertheless thankfulness for sharing this info. power washing lakewood ranch

Contents:

MakeDoc2 by REBOL- 22-Sep-2023
34
angel17
27-Nov-2023 6:50
What an awesome post. Thanks for sharing this one. full service property management Scottsdale, LA 
35
saruonhosari
26-Jan 23:42
Edited:
saruonhosari
26-Jan 23:42
REBOL

Our portable sanitation services may be a behind-the-scenes part of event planning but holding an event without them could lead to lots of unhappy guests. Let us help your event be a success!

Contents:

https://www.jeffersonvilleportapottyservice.com

MakeDoc2 by REBOL- 26-Jan-2024
36
marie
4-Mar 0:30
REBOL

Discussion posts for script associate.r

Contents:

https://www.flashpartyphotobooth.com/frisco

MakeDoc2 by REBOL- 4-Mar-2024
37
kyzer
6-Mar 6:39
REBOL

Thank you for sharing this great post. concrete driveway

Contents:

MakeDoc2 by REBOL- 6-Mar-2024
38
mitch
6-Jul 9:26
REBOL

Such a great site to visit. commercial window cleaning

Contents:

MakeDoc2 by REBOL- 6-Jul-2024
39
olive
6-Jul 11:20
REBOL

This is awesome! It's a very informative site to visit. window cleaning

Contents:

MakeDoc2 by REBOL- 6-Jul-2024
40
annasmith
16-Jul 10:33
REBOL

It's nice seeing this great content. Thanks for sharing. Tradesmen

Contents:

MakeDoc2 by REBOL- 16-Jul-2024
41
breana
5-Aug 11:31
REBOL

I appreciate the effort you put into researching and providing detailed information. concrete driveway

Contents:

MakeDoc2 by REBOL- 5-Aug-2024
42
janwil
5-Aug 11:33
REBOL

Great shared post. Thanks! epoxy flooring sunshine coast

Contents:

MakeDoc2 by REBOL- 5-Aug-2024
43
crutcherhuyn
28-Sep 5:58
REBOL

Our experts handle camshaft repairs with precision, ensuring accurate engine timing and functionality.

Contents:

mechanic mobile service

MakeDoc2 by REBOL- 28-Sep-2024
44
blythewoody
18-Oct 13:11
REBOL

That's not a silly question at all! In Haskell, the concept you're describing—an associative array or hash in Perl terms—is typically implemented with maps (e.g., Data.Map or Data.HashMap). These data structures allow you to associate keys with values, similar to associative arrays or hashes in other languages.

Contents:

However, attoparsec is a parser combinator library, so its primary purpose is to construct parsers for processing input (usually text or binary data). It doesn't directly create associative arrays or maps like Data.Map, but it can be used to parse input that gets stored in such structures.

For instance, you could use attoparsec to parse a configuration file or JSON object where you want to map keys to values. Once you've parsed the input, you could store the parsed data in something like a Map for easy lookup, mimicking the behavior of an associative array.

Example of how you might combine attoparsec with a Map:

haskell Copy code import Data.Map (Map) import qualified Data.Map as Map import Data.Attoparsec.Text import Data.Text (Text)

-- Parser for key-value pairs keyValuePair :: Parser (Text, Text) keyValuePair = do

key <- takeTill (== ':')
char ':'
value <- takeTill isEndOfLine
endOfLine
return (key, value)

-- Parser for a map of key-value pairs keyValuePairs :: Parser (Map Text Text) keyValuePairs = Map.fromList <$> many' keyValuePair

-- Example usage: -- Parsing a configuration-like string into a Map exampleInput = "foo:bar\nbaz:qux\n" parsedResult = parseOnly keyValuePairs exampleInput This would result in a Map that behaves similarly to an associative array:

haskell Copy code fromList [("foo", "bar"), ("baz", "qux")] So, attoparsec parses the data, and then you could store it in an associative array-like structure. Swimming pool contractor in Raleigh NC

MakeDoc2 by REBOL- 18-Oct-2024
45
hiranochie
20-Oct 23:49
REBOL

Manfaatkan promo eksklusif pemain baru dan mulai petualangan slot dewapoker88Anda dengan kemenangan besar daftarkan diri Anda sekarang di website kami! Raih kemenangan besar dengan promo spesial pemain baru di website poker88 asiakami daftar sekarang dan nikmati bonus besar yang akan membuat pengalaman bermain Anda semakin menarik!

Contents:

MakeDoc2 by REBOL- 20-Oct-2024
46
odakameko
20-Oct 23:49
REBOL

Promo eksklusif hanya untuk pemain baru! Daftar sekarang di website login dewapokerkami dan dapatkan bonus besar yang akan meningkatkan peluang Anda untuk memenangkan hadiah besar! Hadiah besar menanti Anda dengan promo khusus pemain baru daftarlah sekarang di website daftar dominobetkami dan mulailah perjalanan Anda menuju jackpot besar!

Contents:

MakeDoc2 by REBOL- 20-Oct-2024
47
odakameko
20-Oct 23:50
REBOL

Untitled

Contents:

MakeDoc2 by REBOL- 20-Oct-2024
48
blythewoody
2-Dec 11:05
REBOL

Not a silly question at all! Yes, many programming constructs or data structures can create something similar to an associative array (or a "hash" in Perl) depending on the context. An associative array is a collection of key-value pairs, where keys are unique and are used to retrieve the corresponding values.

Contents:

Here’s how some common languages approach this:

Perl: Uses hashes directly. For example:

perl Copy code my %hash = (key1 => "value1", key2 => "value2"); print $hash{key1}; # Outputs "value1" JavaScript: Uses objects or Maps:

javascript Copy code let obj = { key1: "value1", key2: "value2" }; console.log(obj.key1); // Outputs "value1" Or with Map:

javascript Copy code let map = new Map(); map.set("key1", "value1"); console.log(map.get("key1")); // Outputs "value1" Python: Uses dictionaries:

python Copy code my_dict = {"key1": "value1", "key2": "value2"} print(my_dict["key1"]) # Outputs "value1" Ruby: Uses hashes, much like Perl:

ruby Copy code hash = { key1: "value1", key2: "value2" } puts hash[:key1] # Outputs "value1" Haskell: Uses data structures like Data.Map for an associative array-like behavior:

haskell Copy code import qualified Data.Map as Map let myMap = Map.fromList [("key1", "value1"), ("key2", "value2")] print (Map.lookup "key1" myMap) -- Outputs "Just "value1"" C: You’d typically use a custom structure or library (like glib for a hash table).

The specific implementation you're asking about depends on the language you're working in and the actual code snippet. Associative arrays (or similar data structures) are universal in concept, though terminology and implementation details vary between programming environments. Ibis Egozi Realtor

MakeDoc2 by REBOL- 2-Dec-2024
49
olive
4-Dec 12:49
REBOL

I would love to see more articles from this site. learn more

Contents:

MakeDoc2 by REBOL- 4-Dec-2024