Rocksolid Light

Welcome to novaBBS (click a section below)

mail  files  register  newsreader  groups  login

Message-ID:  

6 May, 2024: The networking issue during the past two days has been identified and may be fixed. Will keep monitoring.


devel / comp.lang.xharbour / Adding element of one array at the end of anothar array

SubjectAuthor
* Adding element of one array at the end of anothar arrayMarco Boschi
+- Adding element of one array at the end of anothar arrayAriel Paredes
`* Adding element of one array at the end of anothar arrayDan
 `- Adding element of one array at the end of anothar arrayMarco Boschi

1
Adding element of one array at the end of anothar array

<eafdaeee-9164-4bab-990a-cafe255ec9c4n@googlegroups.com>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=10576&group=comp.lang.xharbour#10576

  copy link   Newsgroups: comp.lang.xharbour
X-Received: by 2002:ac8:7c49:0:b0:31e:c751:82a0 with SMTP id o9-20020ac87c49000000b0031ec75182a0mr20957230qtv.612.1658152234999;
Mon, 18 Jul 2022 06:50:34 -0700 (PDT)
X-Received: by 2002:a05:6214:21e1:b0:473:856d:8f6c with SMTP id
p1-20020a05621421e100b00473856d8f6cmr21171677qvj.116.1658152234852; Mon, 18
Jul 2022 06:50:34 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!news.misty.com!border2.nntp.dca1.giganews.com!nntp.giganews.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.lang.xharbour
Date: Mon, 18 Jul 2022 06:50:34 -0700 (PDT)
Injection-Info: google-groups.googlegroups.com; posting-host=185.55.90.130; posting-account=_oyAawkAAAAkDmcMkD9UQrwxJqiaol5l
NNTP-Posting-Host: 185.55.90.130
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <eafdaeee-9164-4bab-990a-cafe255ec9c4n@googlegroups.com>
Subject: Adding element of one array at the end of anothar array
From: inf...@marcoboschi.it (Marco Boschi)
Injection-Date: Mon, 18 Jul 2022 13:50:34 +0000
Content-Type: text/plain; charset="UTF-8"
Lines: 21
 by: Marco Boschi - Mon, 18 Jul 2022 13:50 UTC

Hi to all!

Is it possible to add elements of aSoloRic Array after this sequence { "ONE" , "TWO" , "THREE" , "FOUR" , "FIVE" } using a particular syntax?

For every line of aResult Array I Have 5 fixed elements and than other elements but I don't know how many.
aSoloRic could contain from zero to n elements

otherwise I Create a little function to goal

FUNCTION MAIN()

LOCAL aSoloRic1 := {}
LOCAL aResult := {}

aSoloRic1 := { "0001" , "0002" , "0003" , "0004" }

AADD( aResult , { "ONE" , "TWO" , "THREE" , "FOUR" , "FIVE" , aSoloRic1 } )

RETURN NIL

Re: Adding element of one array at the end of anothar array

<21e59b89-c438-4445-9d53-6448505697c7n@googlegroups.com>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=10577&group=comp.lang.xharbour#10577

  copy link   Newsgroups: comp.lang.xharbour
X-Received: by 2002:a05:622a:589:b0:319:ddca:37e4 with SMTP id c9-20020a05622a058900b00319ddca37e4mr28135611qtb.36.1658322390721;
Wed, 20 Jul 2022 06:06:30 -0700 (PDT)
X-Received: by 2002:a05:620a:c43:b0:6a9:77ef:e000 with SMTP id
u3-20020a05620a0c4300b006a977efe000mr24805323qki.396.1658322390451; Wed, 20
Jul 2022 06:06:30 -0700 (PDT)
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!feed1.usenet.blueworldhosting.com!peer03.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.xharbour
Date: Wed, 20 Jul 2022 06:06:30 -0700 (PDT)
In-Reply-To: <eafdaeee-9164-4bab-990a-cafe255ec9c4n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=2806:10b7:2:8870:5c73:5292:fde6:2062;
posting-account=yPVU0woAAABt-Dryqf89b-v6ZIg0f0od
NNTP-Posting-Host: 2806:10b7:2:8870:5c73:5292:fde6:2062
References: <eafdaeee-9164-4bab-990a-cafe255ec9c4n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <21e59b89-c438-4445-9d53-6448505697c7n@googlegroups.com>
Subject: Re: Adding element of one array at the end of anothar array
From: arielsol...@gmail.com (Ariel Paredes)
Injection-Date: Wed, 20 Jul 2022 13:06:30 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 2551
 by: Ariel Paredes - Wed, 20 Jul 2022 13:06 UTC

El lunes, 18 de julio de 2022 a las 8:50:35 UTC-5, Marco Boschi escribió:
> Hi to all!
>
> Is it possible to add elements of aSoloRic Array after this sequence { "ONE" , "TWO" , "THREE" , "FOUR" , "FIVE" } using a particular syntax?
>
> For every line of aResult Array I Have 5 fixed elements and than other elements but I don't know how many.
> aSoloRic could contain from zero to n elements
>
>
> otherwise I Create a little function to goal
>
>
>
> FUNCTION MAIN()
>
> LOCAL aSoloRic1 := {}
> LOCAL aResult := {}
>
> aSoloRic1 := { "0001" , "0002" , "0003" , "0004" }
>
> AADD( aResult , { "ONE" , "TWO" , "THREE" , "FOUR" , "FIVE" , aSoloRic1 } )
>
> RETURN NIL

Hi
try Hash

// The example creates an associative array and deletes
// the third key/value pair.
PROCEDURE Main
LOCAL hArray := Hash()
HSetAACompatibility( hArray, .T. )
hArray[ "One" ] := 10
hArray[ "Two" ] := 20
hArray[ "Three"] := 30
hArray[ "Four" ] := 40
hArray[ "Five" ] := 50
? hArray[ 3 ] // result: 30
? hArray["Four"] // result: 40
HaaDelAt( hArray, 3 )
? hArray[ 3 ] // result: 40
? hArray["Four"] // result: 40
RETURN

Re: Adding element of one array at the end of anothar array

<tb922k$1ll2t$1@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=10578&group=comp.lang.xharbour#10578

  copy link   Newsgroups: comp.lang.xharbour
Path: i2pn2.org!i2pn.org!eternal-september.org!reader01.eternal-september.org!.POSTED!not-for-mail
From: webmas...@appliserver.com (Dan)
Newsgroups: comp.lang.xharbour
Subject: Re: Adding element of one array at the end of anothar array
Date: Wed, 20 Jul 2022 16:05:04 +0200
Organization: A noiseless patient Spider
Lines: 43
Message-ID: <tb922k$1ll2t$1@dont-email.me>
References: <eafdaeee-9164-4bab-990a-cafe255ec9c4n@googlegroups.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Wed, 20 Jul 2022 14:05:08 -0000 (UTC)
Injection-Info: reader01.eternal-september.org; posting-host="d8be730129e2ff236f8a0d7ff30dd7bf";
logging-data="1758301"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18VrDenvs8Zs+15Z/tUc696"
User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:91.0) Gecko/20100101
Thunderbird/91.11.0
Cancel-Lock: sha1:YEwpDmxhGDe3JvLuwTYD55qTqbM=
In-Reply-To: <eafdaeee-9164-4bab-990a-cafe255ec9c4n@googlegroups.com>
 by: Dan - Wed, 20 Jul 2022 14:05 UTC

Il 18/07/2022 15:50, Marco Boschi ha scritto:
> Hi to all!
>
> Is it possible to add elements of aSoloRic Array after this sequence { "ONE" , "TWO" , "THREE" , "FOUR" , "FIVE" } using a particular syntax?
>
> For every line of aResult Array I Have 5 fixed elements and than other elements but I don't know how many.
> aSoloRic could contain from zero to n elements
>
>
> otherwise I Create a little function to goal
>
>
>
> FUNCTION MAIN()
>
> LOCAL aSoloRic1 := {}
> LOCAL aResult := {}
>
> aSoloRic1 := { "0001" , "0002" , "0003" , "0004" }
>
> AADD( aResult , { "ONE" , "TWO" , "THREE" , "FOUR" , "FIVE" , aSoloRic1 } )
>
> RETURN NIL

LOCAL aSoloRic1 := { "0001" , "0002" , "0003" , "0004" }
LOCAL aResult := {}
AADD( aResult , { "ONE" , "TWO" , "THREE" , "FOUR" , "FIVE"})

// aResult={{ "ONE" , "TWO" , "THREE" , "FOUR" , "FIVE"}}
// aresult[1] is the first element of array aResult and it is an array
itself. It is NOT aResult={ "ONE" , "TWO" , "THREE" , "FOUR" , "FIVE"}

aeval(aSoloRic1,{|x|aadd(aResult[1],x)})

// we added elements to the sub-array
// aResult={{ "ONE" , "TWO" , "THREE" , "FOUR" , "FIVE", "0001" ,
"0002" , "0003" , "0004" }}
// Otherwise you obtain:
// aResult={{ "ONE" , "TWO" , "THREE" , "FOUR" , "FIVE"},{"0001" ,
"0002" , "0003" , "0004" }}

HTH
Dan

Re: Adding element of one array at the end of anothar array

<8eba3af1-e3ec-4c10-a43d-585fa99dafd3n@googlegroups.com>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=10579&group=comp.lang.xharbour#10579

  copy link   Newsgroups: comp.lang.xharbour
X-Received: by 2002:a05:6214:4115:b0:473:4828:a8ef with SMTP id kc21-20020a056214411500b004734828a8efmr32767810qvb.62.1658389465411;
Thu, 21 Jul 2022 00:44:25 -0700 (PDT)
X-Received: by 2002:ac8:5756:0:b0:31e:c569:171f with SMTP id
22-20020ac85756000000b0031ec569171fmr32718747qtx.451.1658389465251; Thu, 21
Jul 2022 00:44:25 -0700 (PDT)
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!feed1.usenet.blueworldhosting.com!peer03.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.xharbour
Date: Thu, 21 Jul 2022 00:44:25 -0700 (PDT)
In-Reply-To: <tb922k$1ll2t$1@dont-email.me>
Injection-Info: google-groups.googlegroups.com; posting-host=185.55.90.130; posting-account=_oyAawkAAAAkDmcMkD9UQrwxJqiaol5l
NNTP-Posting-Host: 185.55.90.130
References: <eafdaeee-9164-4bab-990a-cafe255ec9c4n@googlegroups.com> <tb922k$1ll2t$1@dont-email.me>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <8eba3af1-e3ec-4c10-a43d-585fa99dafd3n@googlegroups.com>
Subject: Re: Adding element of one array at the end of anothar array
From: inf...@marcoboschi.it (Marco Boschi)
Injection-Date: Thu, 21 Jul 2022 07:44:25 +0000
Content-Type: text/plain; charset="UTF-8"
X-Received-Bytes: 1182
 by: Marco Boschi - Thu, 21 Jul 2022 07:44 UTC

Many thanks to all!

1
server_pubkey.txt

rocksolid light 0.9.81
clearnet tor