Re: Counter Help

2016-02-12 Thread Kent Fredric
On 13 February 2016 at 10:08, Kent Fredric  wrote:
>
> All you're doing is sorting the *view* of it. Not the data itself.


If you want a demonstration of this fact, on a Linux filesystem, poke
around with 'find'. Or if you've got Path::Iterator::Rule installed:

 perl -MPIR -E' $it = PIR->new->iter_fast(q(.)); while( my $entry =
$it->() ) { say $entry }'

You'll notice that the output frequently /appears/ partly sorted.

But often doesn't seem sorted at all.

tools like 'ls' make this simple for you because they automatically
sort things to display it, but the folder itself is typically not
"sorted", all you've sorted is "a list of files that you retrieved
from a folder"

Similarly, you can "sort" the list of "keys" that come out of a hash,
but you can't sort the hash itself.

my @keys = sort keys %hash;

( Hashes and Filesystems themselves, however, are stored unsorted,
because it is typically faster for the operating system to do it that
way, and then only sort it for presentation purposes when strictly
necessary , because sorting is expensive, so it delays doing it at all
until the very last possible oppotunity )

-- 
Kent

KENTNL - https://metacpan.org/author/KENTNL

-- 
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




Re: Counter Help

2016-02-12 Thread Kent Fredric
On 13 February 2016 at 08:38, timothy adigun <2teezp...@gmail.com> wrote:
> In your analogy, if hashes are like folder,  keys and values are like what?
> Name of folders. If yes,  can those be sorted?  If yes,  they you have just
> made my point..  :)


Keys are files.

Values are file contents.

But no, the folders themselves cannot be "Sorted", sorting modifies
the *property* of the thing.

What you are doing, is sorting how it is *displayed*

If you used low-level mechanics to look at how the files are laid out
on the filesystem, the files in those folders wouldn't necessarily
even be stored near each other. "Soriting" them as such would be an
expensive mechanism moving stuff all over your hard drive.

All you're doing is sorting the *view* of it. Not the data itself.

-- 
Kent

KENTNL - https://metacpan.org/author/KENTNL

-- 
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




RE: Counter Help

2016-02-12 Thread uri
On Fri, February 12, 2016 12:37 pm, Christin Deville wrote:
> I have been lurking for a while but I want to chime in and say thanks for
> that piece of advice. I've been trying to sort out in my head when to use
> a hash or an array and this all helps!
>
>

in real world code you should be using hashes way more often than arrays.
arrays map to stacks, lists, fifo, etc. which is just a few concepts.
hashes map to many more concepts: data structures, sets, tables,
dispatching, lookup by name, mapping from one domain to another, inclusion
tests, etc. it is almost never a choice of which to use. it should be
plain to see when a hash or array is needed. study some good cpan code and
you will see that hashes are much more common than arrays in perl.

some notes to keep around:

arrays are indexed by integers
hashes are indexed by strings (keys)

arrays are ordered (by their integer indexes)
hashes are unordered (keys are not presorted)

arrays can be added to at their beginning (unshift) or end (push) or
inside (splice). those are all functions. you can delete from the
beginning with shift or the end with pop. deleting from the middle with
splice().
hashes can be added to by assignment, and keys can be deleted by delete().

you loop over arrays with foreach and get their values
you loop over hash keys with foreach/keys() (only get keys), while/each()
(can get keys and values).

arrays and hashes have very similar syntax. the sigils are @ vs % and the
indexing delimiters are [] vs {} (same for anon refs to them).

uri





-- 
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




Re: Counter Help

2016-02-12 Thread timothy adigun
On Feb 12, 2016 8:28 PM, "Kent Fredric"  wrote:
>
> On 13 February 2016 at 07:39, timothy adigun <2teezp...@gmail.com> wrote:
> > And hashes keys/values can't be sorted? Just saying.. :)
>
>
> In my other message where I give an analogy to a "Folder" or
> "Directory" in a file system.
In your analogy, if hashes are like folder,  keys and values are like
what?  Name of folders. If yes,  can those be sorted?  If yes,  they you
have just made my point..  :)
>
> Can you sort a folder? ... not really. They don't really have an
> "order", you can traverse them in an order, but there's lots of
> different ways of doing that.
>
> The folder itself is, under the hood, sorted somewhat randomly most of
> the time, and your user interface might just sort them before you get
> what comes out of it ;).
>
> You can demonstrate this by asking somebody to change the order of 2
> specific files in a folder without changing the name, and then watch
> as they fail :P
>
>
>
> --
> Kent
>
> KENTNL - https://metacpan.org/author/KENTNL


Re: Counter Help

2016-02-12 Thread Kent Fredric
On 13 February 2016 at 07:39, timothy adigun <2teezp...@gmail.com> wrote:
> And hashes keys/values can't be sorted? Just saying.. :)


In my other message where I give an analogy to a "Folder" or
"Directory" in a file system.

Can you sort a folder? ... not really. They don't really have an
"order", you can traverse them in an order, but there's lots of
different ways of doing that.

The folder itself is, under the hood, sorted somewhat randomly most of
the time, and your user interface might just sort them before you get
what comes out of it ;).

You can demonstrate this by asking somebody to change the order of 2
specific files in a folder without changing the name, and then watch
as they fail :P



-- 
Kent

KENTNL - https://metacpan.org/author/KENTNL

-- 
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




Re: Counter Help

2016-02-12 Thread Kent Fredric
On 10 February 2016 at 03:46, James Kerwin  wrote:
> (I'm a bit wary of hashes because they're weird).


If you want a nice way to reason about hashes when you're really new,
there's something that you probably already understand you can borrow
understanding from:

Folders.

A hash is like a folder.

And every key is like a file.

And you can trivially demonstrate this with this code that treats a
folder as a storage mechanism.

For every item you see:

1. Look in the folder for a file with the same name.
2. Does it exist? No, then its zero
yes? Then read what number it currently has in it
3. Add one to that number
4. write that file out again.
5. Append that number to the item.

https://gist.github.com/kentfredric/8b90c88e20c7af9b1252


Now, this has the obvious limitation that this data structure persists
its data between runs, so every time you run the script, the numbers
will get bigger, and you'll have to nuke that script between runs.

But that's basically what the hash is doing for you.

Its a collection ( Folder / Hash ), ordered by keys ( like filenames
), that contain data ( like file contents ).

The only distinction you need to immediately worry about is that
Hashes happen entirely in memory, and they evaporate
as soon as your program stops.

I wouldn't recommend using the file technique for any real purpose,
but its interesting from an education perspective.


-- 
Kent

KENTNL - https://metacpan.org/author/KENTNL

-- 
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




Re: Counter Help

2016-02-12 Thread timothy adigun
On Feb 12, 2016 6:22 PM, "Shawn H Corey"  wrote:
>
> On Fri, 12 Feb 2016 12:08:07 -0500
> Uri Guttman  wrote:
>
> > hashes are very easy to learn. and once you get the hang of them you
> > will wonder why you waited so long.
>
> If keeping the data ordering is important,
And hashes keys/values can't be sorted? Just saying.. :)
>use an array. Otherwise, use
> a hash. :)
>
>
> --
> Don't stop where the ink does.
> Shawn
>
> --
> To unsubscribe, e-mail: beginners-unsubscr...@perl.org
> For additional commands, e-mail: beginners-h...@perl.org
> http://learn.perl.org/
>
>


RE: Counter Help

2016-02-12 Thread Christin Deville
I have been lurking for a while but I want to chime in and say thanks for that 
piece of advice. I've been trying to sort out in my head when to use a hash or 
an array and this all helps!

-Christin

-Original Message-
From: Shawn H Corey [mailto:shawnhco...@gmail.com] 
Sent: Friday, February 12, 2016 10:21 AM
To: beginners@perl.org
Subject: Re: Counter Help

On Fri, 12 Feb 2016 12:08:07 -0500
Uri Guttman  wrote:

> hashes are very easy to learn. and once you get the hang of them you 
> will wonder why you waited so long.

If keeping the data ordering is important, use an array. Otherwise, use a hash. 
:)


--
Don't stop where the ink does.
Shawn

--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, 
e-mail: beginners-h...@perl.org http://learn.perl.org/



--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




Re: Counter Help

2016-02-12 Thread Uri Guttman

On 02/12/2016 04:33 AM, James Kerwin wrote:

Thank you all for your help; all suggestions were welcome and helpful.

I didn't give the full details but Jim's solution did what I wanted 
the best and after reading around I think I get it. I've sat here 
trying to "break" it for the past half an hour and so far so good.


I solemnly swear to properly learn hashes and use them (and to stop 
thinking of them as "weird").




if you are not using hashes and regexes, you are not coding in perl. :)

hashes are very easy to learn. and once you get the hang of them you 
will wonder why you waited so long.


uri





--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




Re: Counter Help

2016-02-12 Thread Shawn H Corey
On Fri, 12 Feb 2016 12:08:07 -0500
Uri Guttman  wrote:

> hashes are very easy to learn. and once you get the hang of them you 
> will wonder why you waited so long.

If keeping the data ordering is important, use an array. Otherwise, use
a hash. :)


-- 
Don't stop where the ink does.
Shawn

-- 
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




Re: Counter Help

2016-02-12 Thread James Kerwin
Thank you all for your help; all suggestions were welcome and helpful.

I didn't give the full details but Jim's solution did what I wanted the
best and after reading around I think I get it. I've sat here trying to
"break" it for the past half an hour and so far so good.

I solemnly swear to properly learn hashes and use them (and to stop
thinking of them as "weird").

Again, thank you for the help! It's very appreciated.

James.

On Tue, Feb 9, 2016 at 6:37 PM, Jim Gibson  wrote:

>
> > On Feb 9, 2016, at 6:46 AM, James Kerwin  wrote:
> >
> > Thank you both very much for your help. I'll investigate this way when I
> get home later (I'm a bit wary of hashes because they're weird).
>
> Here is a solution using a hash:
>
> #!/usr/bin/perl
> use strict;
> use warnings;
>
> my @array = qw{
>11_
>22_
>22_
>33_
>33_
>33_
>44_
>44_
>55_
> };
>
> my %count;
> for my $element ( @array ) {
>   $element .= ++$count{$element};
> }
>
> print "Array:\n\n  ". join("\n  ",@array) . "\n”;
>
> __END__
>
> Note that the array needn’t be sorted for this method to work.
> --
> To unsubscribe, e-mail: beginners-unsubscr...@perl.org
> For additional commands, e-mail: beginners-h...@perl.org
> http://learn.perl.org/
>
>
>


Re: Counter Help

2016-02-09 Thread Jim Gibson

> On Feb 9, 2016, at 6:46 AM, James Kerwin  wrote:
> 
> Thank you both very much for your help. I'll investigate this way when I get 
> home later (I'm a bit wary of hashes because they're weird).

Here is a solution using a hash:

#!/usr/bin/perl
use strict;
use warnings;

my @array = qw{
   11_
   22_
   22_
   33_
   33_
   33_
   44_
   44_
   55_
};

my %count;
for my $element ( @array ) {
  $element .= ++$count{$element};
}

print "Array:\n\n  ". join("\n  ",@array) . "\n”;

__END__

Note that the array needn’t be sorted for this method to work.
--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




Re: Counter Help

2016-02-09 Thread Shlomi Fish
Hi Duncan and James,

On Tue, 9 Feb 2016 14:58:05 +
Duncan Ferguson  wrote:

> I disagree – hashes are not weird – they are incredibly useful.  It is just
> an array indexed by a word instead of a number  ☺
> 

I agree with Duncan here. Hashes are an integral part of idiomatic Perl and one
should learn how to use them properly and use them often - when appropriate.
For some resources for learning about hashes see:

* http://perl-begin.org/topics/hashes/

Otherwise, James’s code suffers from many bad idioms. For how to improve it,
see:

* http://perl-begin.org/tutorials/bad-elements/

(Note: perl-begin.org is a web site that I maintain.)

Below is one comment on Duncan's code:

> 
> 
> Here is some working code that may help
> 
> ===
> 
> #!/usr/bin/perl
> 
> use strict;
> 
> use warnings;
> 
> 
> 
> my @array = ( qw/ 11_ 22_ 33_ 33_ 33_ 44_ 44_ 55_ / );
> 
> 
> 
> my %results;
> 
> 
> 
> # create a hash of arrays
> 
> for my $item (@array) {
> 
> push(@{ $results{$item} }, $item);
> 
> }
> 
> 
> 
> # For each entry in the hash
> 
> for my $key (sort(keys(%results))) {
> 
># make a local array back out of what is stored in the hash
> 
> my @arr = @{ $results{$key}};
> 
> print "key=$key:", $/;
> 
> # print out the indexes of items in the local array
> 
> print "  $key$_",$/ foreach (0 .. $#arr)
> 

Since you're only using key and the length of the $results{$key} array
reference, you might as well just store a count which you can increment using
either of the ++ operators. Moreover, do you wish to preserve the order of the
occurrences?

Regards,

Shlomi Fish

--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




Re: Counter Help

2016-02-09 Thread Nathan Hilterbrand



On 02/09/2016 09:08 AM, James Kerwin wrote:

Afternoon all,

I have the following problem:

I have an array containing a list of non-unique strings. eg:

@array Contains:

11_
22_
33_
33_
33_
44_
44_
55_

What I would like to do is number each element of the array to look as 
follows:


11_1
22_1
33_1
33_2
33_3
44_1
44_2
55_1

I have so far tried to use "exists", while loops and all the usual 
stuff as it seemed very simple at first. My attempts have mostly 
focused on equating the current element of the array with the previous 
one and asking if they are equal and then taking action. I just can't 
get the logic right though. I keep getting them all numbered 
sequentially from 1 to 10 or they all end in "_2" or alternating "_1" 
and "_2" If anybody could shed even the smallest glimmer of light on 
how to solve this I'd be really grateful.


Thanks,
James.



Personally, I would normally use a hash.  However, one hashless solution 
might be:


#!/usr/bin/perl

  use strict;
  use warnings;


  my @array = qw{
11_
22_
33_
33_
33_
44_
44_
55_
};


  my $lastelem = '';
  my $count;
  for my $element (@array) {
$count = 1 unless $element eq $lastelem;
$lastelem = $element;
$element .= $count++;
  }

  print map {"$_\n"} @array;


Best of luck

Nathan


--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




RE: Counter Help

2016-02-09 Thread Duncan Ferguson
I disagree – hashes are not weird – they are incredibly useful.  It is just an 
array indexed by a word instead of a number  ☺



Here is some working code that may help

===

#!/usr/bin/perl

use strict;

use warnings;



my @array = ( qw/ 11_ 22_ 33_ 33_ 33_ 44_ 44_ 55_ / );



my %results;



# create a hash of arrays

for my $item (@array) {

push(@{ $results{$item} }, $item);

}



# For each entry in the hash

for my $key (sort(keys(%results))) {

   # make a local array back out of what is stored in the hash

my @arr = @{ $results{$key}};

print "key=$key:", $/;

# print out the indexes of items in the local array

print "  $key$_",$/ foreach (0 .. $#arr)

}



  Duncs





From: James Kerwin [mailto:jkerwin2...@gmail.com]

Sent: 09 February 2016 14:47

Cc: beginners@perl.org

Subject: Re: Counter Help



Thank you both very much for your help. I'll investigate this way when I get 
home later (I'm a bit wary of hashes because they're weird).



As my files are sorted numerically I managed to do the following (it's ugly, 
please don't shout at me):



my $length = (scalar @New)-1;

#print $length;

push (my @other, @New[0]);

foreach (@New){

chop ($_);

#print "$_\n";

}



my $i = 0; my $ii = 1;

foreach (@New[1 .. $length]) {

#foreach (@New){

if ($_ ne $New[$i]){

push (@other, (join "", $_,"1"));

$i++;

}

elsif ($_ eq $New[$i]){

$i++;

$ii++;

push (@other, (join "", $_,$ii));

}}



foreach (@other){



print "$_\n";

}



This gave me the desired output. Like I said, I'll investigate the other way 
later...



Thanks,

James.



On Tue, Feb 9, 2016 at 2:22 PM, Jim Gibson  wrote:



> On Feb 9, 2016, at 6:08 AM, James Kerwin  wrote:

>

> Afternoon all,

>

> I have the following problem:

>

> I have an array containing a list of non-unique strings. eg:

>

> @array Contains:

>

> 11_

> 22_

> 33_

> 33_

> 33_

> 44_

> 44_

> 55_

>

> What I would like to do is number each element of the array to look as 
> follows:

>

> 11_1

> 22_1

> 33_1

> 33_2

> 33_3

> 44_1

> 44_2

> 55_1

>

> I have so far tried to use "exists", while loops and all the usual stuff as 
> it seemed very simple at first. My attempts have mostly focused on equating 
> the current element of the array with the previous one and asking if they are 
> equal and then taking action. I just can't get the logic right though. I keep 
> getting them all numbered sequentially from 1 to 10 or they all end in "_2" 
> or alternating "_1" and "_2" If anybody could shed even the smallest glimmer 
> of light on how to solve this I'd be really grateful.



You should define a hash with the strings as keys and the number of strings 
encountered in the array so far as the hash value. You can then add the number 
to each string as you iterate over the array and increment the hash value count.





Jim Gibson

j...@gibson.org









--

To unsubscribe, e-mail: beginners-unsubscr...@perl.org

For additional commands, e-mail: beginners-h...@perl.org

http://learn.perl.org/






Re: Counter Help

2016-02-09 Thread James Kerwin
Thank you both very much for your help. I'll investigate this way when I
get home later (I'm a bit wary of hashes because they're weird).

As my files are sorted numerically I managed to do the following (it's
ugly, please don't shout at me):

my $length = (scalar @New)-1;
#print $length;
push (my @other, @New[0]);
foreach (@New){
chop ($_);
#print "$_\n";
}

my $i = 0; my $ii = 1;
foreach (@New[1 .. $length]) {
#foreach (@New){
if ($_ ne $New[$i]){
push (@other, (join "", $_,"1"));
$i++;
}
elsif ($_ eq $New[$i]){
$i++;
$ii++;
push (@other, (join "", $_,$ii));
}}
foreach (@other){
print "$_\n";
}

This gave me the desired output. Like I said, I'll investigate the other
way later...

Thanks,
James.

On Tue, Feb 9, 2016 at 2:22 PM, Jim Gibson  wrote:

>
> > On Feb 9, 2016, at 6:08 AM, James Kerwin  wrote:
> >
> > Afternoon all,
> >
> > I have the following problem:
> >
> > I have an array containing a list of non-unique strings. eg:
> >
> > @array Contains:
> >
> > 11_
> > 22_
> > 33_
> > 33_
> > 33_
> > 44_
> > 44_
> > 55_
> >
> > What I would like to do is number each element of the array to look as
> follows:
> >
> > 11_1
> > 22_1
> > 33_1
> > 33_2
> > 33_3
> > 44_1
> > 44_2
> > 55_1
> >
> > I have so far tried to use "exists", while loops and all the usual stuff
> as it seemed very simple at first. My attempts have mostly focused on
> equating the current element of the array with the previous one and asking
> if they are equal and then taking action. I just can't get the logic right
> though. I keep getting them all numbered sequentially from 1 to 10 or they
> all end in "_2" or alternating "_1" and "_2" If anybody could shed even the
> smallest glimmer of light on how to solve this I'd be really grateful.
>
> You should define a hash with the strings as keys and the number of
> strings encountered in the array so far as the hash value. You can then add
> the number to each string as you iterate over the array and increment the
> hash value count.
>
>
> Jim Gibson
> j...@gibson.org
>
>
>
>
> --
> To unsubscribe, e-mail: beginners-unsubscr...@perl.org
> For additional commands, e-mail: beginners-h...@perl.org
> http://learn.perl.org/
>
>
>


Re: Counter Help

2016-02-09 Thread Jing Yu via beginners
Hello,

I don’t know whether it is possible to count the occurrence in hash? 

print $var, $myhash{$var}++.”\n”;

Jing
> On 9 Feb 2016, at 14:08, James Kerwin  wrote:
> 
> Afternoon all,
> 
> I have the following problem:
> 
> I have an array containing a list of non-unique strings. eg:
> 
> @array Contains:
> 
> 11_
> 22_
> 33_
> 33_
> 33_
> 44_
> 44_
> 55_
> 
> What I would like to do is number each element of the array to look as 
> follows:
> 
> 11_1
> 22_1
> 33_1
> 33_2
> 33_3
> 44_1
> 44_2
> 55_1
> 
> I have so far tried to use "exists", while loops and all the usual stuff as 
> it seemed very simple at first. My attempts have mostly focused on equating 
> the current element of the array with the previous one and asking if they are 
> equal and then taking action. I just can't get the logic right though. I keep 
> getting them all numbered sequentially from 1 to 10 or they all end in "_2" 
> or alternating "_1" and "_2" If anybody could shed even the smallest glimmer 
> of light on how to solve this I'd be really grateful.
> 
> Thanks,
> James.
> 
>  


--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




Re: Counter Help

2016-02-09 Thread Jim Gibson

> On Feb 9, 2016, at 6:08 AM, James Kerwin  wrote:
> 
> Afternoon all,
> 
> I have the following problem:
> 
> I have an array containing a list of non-unique strings. eg:
> 
> @array Contains:
> 
> 11_
> 22_
> 33_
> 33_
> 33_
> 44_
> 44_
> 55_
> 
> What I would like to do is number each element of the array to look as 
> follows:
> 
> 11_1
> 22_1
> 33_1
> 33_2
> 33_3
> 44_1
> 44_2
> 55_1
> 
> I have so far tried to use "exists", while loops and all the usual stuff as 
> it seemed very simple at first. My attempts have mostly focused on equating 
> the current element of the array with the previous one and asking if they are 
> equal and then taking action. I just can't get the logic right though. I keep 
> getting them all numbered sequentially from 1 to 10 or they all end in "_2" 
> or alternating "_1" and "_2" If anybody could shed even the smallest glimmer 
> of light on how to solve this I'd be really grateful.

You should define a hash with the strings as keys and the number of strings 
encountered in the array so far as the hash value. You can then add the number 
to each string as you iterate over the array and increment the hash value count.


Jim Gibson
j...@gibson.org




--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




Counter Help

2016-02-09 Thread James Kerwin
Afternoon all,

I have the following problem:

I have an array containing a list of non-unique strings. eg:

@array Contains:

11_
22_
33_
33_
33_
44_
44_
55_

What I would like to do is number each element of the array to look as
follows:

11_1
22_1
33_1
33_2
33_3
44_1
44_2
55_1

I have so far tried to use "exists", while loops and all the usual stuff as
it seemed very simple at first. My attempts have mostly focused on equating
the current element of the array with the previous one and asking if they
are equal and then taking action. I just can't get the logic right though.
I keep getting them all numbered sequentially from 1 to 10 or they all end
in "_2" or alternating "_1" and "_2" If anybody could shed even the
smallest glimmer of light on how to solve this I'd be really grateful.

Thanks,
James.