Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?

dokkeldepper's scratchpad

by dokkeldepper (Friar)
on Dec 07, 2005 at 13:35 UTC ( #514832=scratchpad: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download

  1. or download this
    package Location;
    use 5.008001;
    use constant nl=>"\n";
    use constant X=>0; # these are the array fields
    use constant Y=>1;
  2. or download this
    # defaults
        return $default_location->[Y];
  3. or download this
    sub new{
        use integer;
  4. or download this
    sub get_location{
        my $self=shift;
        my $self=shift;
        return $self->get_location->[Y];
  5. or download this
    sub set_location{
        my ($self,$x,$y)=@_;
    # so far so nice
  6. or download this
    use integer; #we use integer coordinates
    use constant nl=>"\n";
    use constant Y=>1;
    # overload => thats new !
    use overloead '<=>' => 'compare';
  7. or download this
    sub compare {
        my ($loc1,$loc2,$rev)=@_;
            return 0;
        return ;

Log In?

What's my password?
Create A New User
Domain Nodelet?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (2)
As of 2022-10-01 10:46 GMT
Find Nodes?
    Voting Booth?
    I prefer my indexes to start at:

    Results (126 votes). Check out past polls.