You can consider a hash to be much like an array, except instead of numerical indexes to access individual elements, you use strings as keys.

# Define an array:
my @basket = qw(apple banana cherry);
# Get an element from the array:
# (remember that indexes are 0-based)
print "The second kind of fruit in the basket is $basket[1]\n";
# Change an element:
$basket[1] = "date";
print "Now it is $basket[1]\n";

The above example shouldn't be unfamiliar. Now, instead of keeping a @basket that tells us what kinds of fruit we have in the basket, let's keep a %basket that can also tell us how much of that kind of fruit we have.