Question: Your challenge is to take an array of strings and output the longest string in the array. So for

```
["tiny", "small", "bigger", "biggest"]

```

the output would be `biggest`.

If two elements of the array have the same length, you should choose the one that appears first in the array. That means if the array looks like this:

```
["one", "two", "no"]

```

the output is `one`, but if the array looked like this:

```
["two", "one", "no"]

```

the output is `two`.

---

As this is [code-golf](/questions/tagged/code-golf "show questions tagged 'code-golf'"), the shortest code in bytes wins.

Answer: 
[Python](https://docs.python.org/), 23 bytes
============================================

```python
lambda a:max(a,key=len)

```

[Try it online!](https://tio.run/##xVRNk5swDL33V2RyIZnJaY@d2V/S9CBAAS/G8vgjlP751LYEgc3O9NTpBQF@enqWnm3n0JN5e9zerw8NY93CAb6P8OsElwHnd43m/LBOmXC6nX4csY3ueDkShfQM0Ifjz/P527pe5fXqcqgSIIeMyNEr@ZpyRKtsjo4CqBZKAuRHH1QBRJpzGJp4y1Fr/l1IWiNQxELtBBwicQ6MPr8YaNacjtovaDFArTQWGDrYIBbZ6GLhwgHGlUwwi1Y0TB6wWyEGeaOBqxvlAPv8OsKK8R528rEubD6ybhwldVVb1sO1knrkuULvP9VgYKlBv1Xf@LW947VS2@1NZIbtrlG/dNso6KTfkYok5Fyj/jaooaGyk07VLwMG14G685iYz2HrgPVPW42GVDDcDLEUmepwqfCucRKPlXZqDaWON9yZpbGvBVKvrCXHUwPpey/k3VOCdJh/JaDfbv8pr/dRLETLzPqEdoXXkr59UWcxlGhMKEbjDuWVoP2SpjsDLvhnN1Kx2bF0Hz8@W8zh6p7/SKHTsXdgdhxyin06rrUdY5mLRy0XhMPkpEESDFj42PVOaSmqFUyc2TeBbTZ7H@2ulAxQ7VyCnQO9gxkS0uDxzu42pBMxsiJr41bEyKfQkXN8D8kCLcuNZhfxPrNdveMrSm4KRs51TfolnyUnsSVZDuY/gKbL@/EH "Python 2 – Try It Online")
[Racket](https://racket-lang.org/), 160 bytes 110 bytes
=======================================================

[Try it online!](https://tio.run/##K0pMzk4t@f9fOScxL12hCMzj4tJISU3LzEvVyFVI1NTITNOw08hJzUsvyQByDSECthrFJUWZeem6EAmN5MQioKQmmmiuRnIKWBwoA1GBJATTowm0L1dBXUPJPy9VSUEppDwfSLrllxaBqMyyVCWgCriCVMJKsCkoBqr4/x8A "Racket – Try It Online") 
First time contributing, advice appreciated!

```
(define(m a)(if(>(length a)1)(if(>=(string-length(car a))(string-length(m(cdr a))))(car a)(m(cdr a)))(car a)))

```

**Ungolfed**

```
(define (m a)
    (if (> (length a) 1)
        (if (>= (string-length (car a)) (string-length (m (cdr a))))
            (car a)
            (m (cdr a))
        )
        (car a)
    )
)

```

Updated solution based on feedback