---
title: "Doing linear scans over an associative array is like trying to club s… — Larry Wall Quote #59 | QuotesBy.net"
description: "Doing linear scans over an associative array is like trying to club someone to death with a loaded Uzi. — a quote by Larry Wall."
image: "https://quotesby.net/wp-content/themes/quotesby-editorial/assets/og-default.png"
---

> # Doing linear scans over an associative array is like trying to club someone to death with a loaded Uzi.

[Larry Wall](https://quotesby.net/Larry-Wall)\#59

[Performance](https://quotesby.net/Larry-Wall/performance/)[Efficiency](https://quotesby.net/Larry-Wall/efficiency/)[Structure](https://quotesby.net/Larry-Wall/structure/)[Data](https://quotesby.net/topics/data/)

[WhatsApp (opens in a new tab)](https://wa.me/?text=%E2%80%9CDoing%20linear%20scans%20over%20an%20associative%20array%20is%20like%20trying%20to%20club%20someone%20to%20death%20with%20a%20loaded%20Uzi.%E2%80%9D%20%E2%80%94%20Larry%20Wall%20https%3A%2F%2Fquotesby.net%2FLarry-Wall%2F59%2F)[X (opens in a new tab)](https://twitter.com/intent/tweet?text=%E2%80%9CDoing%20linear%20scans%20over%20an%20associative%20array%20is%20like%20trying%20to%20club%20someone%20to%20death%20with%20a%20loaded%20Uzi.%E2%80%9D%20%E2%80%94%20Larry%20Wall&url=https%3A%2F%2Fquotesby.net%2FLarry-Wall%2F59%2F)[Facebook (opens in a new tab)](https://www.facebook.com/sharer/sharer.php?u=https%3A%2F%2Fquotesby.net%2FLarry-Wall%2F59%2F)

## About this quote

What does it mean?The quote likens scanning an associative array to using an overkill weapon, highlighting inefficiency.In plain termsScanning an associative array is like using a loaded Uzi to club someone.What can you take from it?Choose appropriate algorithms for data structures.

### Where it applies

- large dataset processing
- real‑time systems

### Putting it to work

- use indexed lookups
- avoid linear scans

### Questions to consider

- When is a simple approach sufficient?
- How do you decide algorithm complexity?

### Another view

Sometimes linear scans are acceptable for small data.

## More from Larry Wall

1. > You have to admit that it's difficult to misplace the Perl sources. :-)

[Permalink to quote \#58](https://quotesby.net/Larry-Wall/58/ "Permalink to quote 58")
2. > Well, enough clowning around. Perl is, in intent, a cleaned up and summarized version of that wonderful semi-natural language known as 'Unix'.

[Permalink to quote \#60](https://quotesby.net/Larry-Wall/60/ "Permalink to quote 60")
3. > What is the sound of Perl? Is it not the sound of a wall that people have stopped banging their heads against?

[Permalink to quote \#57](https://quotesby.net/Larry-Wall/57/ "Permalink to quote 57")

## Related quotes

1. > To add speed, add lightness.

[Colin Chapman](https://quotesby.net/Colin-Chapman)[Colin Chapman quote \#4](https://quotesby.net/Colin-Chapman/4/ "Permalink to quote 4")
2. > 'Without the hard little bits of marble which are called 'facts' or 'data' one cannot compose a mosaic; what matters, however, are not so much the individual b…

[Arthur Koestler](https://quotesby.net/Arthur-Koestler)[Arthur Koestler quote \#6](https://quotesby.net/Arthur-Koestler/6/ "Permalink to quote 6")
3. > We're not the Grateful Dead or Pink Floyd. We're Linkin Park, and we cut all the fat out. We don't do guitar or drum solos.

[Chester Bennington](https://quotesby.net/Chester-Bennington)[Chester Bennington quote \#13](https://quotesby.net/Chester-Bennington/13/ "Permalink to quote 13")

```json
{
    "@context": "https://schema.org",
    "@type": "Quotation",
    "text": "Doing linear scans over an associative array is like trying to club someone to death with a loaded Uzi.",
    "url": "https://quotesby.net/Larry-Wall/59/",
    "spokenByCharacter": {
        "@type": "Person",
        "name": "Larry Wall"
    }
}
{
    "@context": "https://schema.org",
    "@type": "BreadcrumbList",
    "itemListElement": [
        {
            "@type": "ListItem",
            "position": 1,
            "name": "Home",
            "item": "https://quotesby.net/"
        },
        {
            "@type": "ListItem",
            "position": 2,
            "name": "Authors",
            "item": "https://quotesby.net/authors/"
        },
        {
            "@type": "ListItem",
            "position": 3,
            "name": "Larry Wall",
            "item": "https://quotesby.net/Larry-Wall"
        },
        {
            "@type": "ListItem",
            "position": 4,
            "name": "Quote #59",
            "item": "https://quotesby.net/Larry-Wall/59/"
        }
    ]
}
```
