Answers for "how to find shortest string in a list python"

0

how to find shortest string in a list python

strings = ["some", "example", "words", "that", "i", "am", "fond", "of"]

print min(strings, key=len) # prints "i"
Posted by: Guest on February-16-2022
0

how to find shortest string in a list python

strings = ["some", "example", "words", "that", "i", "am", "fond", "of"]

print min(strings, key=len) # prints "i"
Posted by: Guest on February-16-2022

Code answers related to "how to find shortest string in a list python"

Python Answers by Framework

Browse Popular Code Answers by Language