Find the words in English that read the same backward and forward.
Run the code to reverse the word “rhinoceros”. Try other words, like your name:
"rhinoceros" is a string of letters: the quotes mean that it’s text, not a computer command.
StringReverse is a Wolfram Language function that reverses a string.
The output doesn’t display quotes, but it’s a string too.
Get a list of dictionary words in English:
Note: the list is automatically shortened because it is very long.
Select words that have length 10. Try other lengths:
StringLength gives the length of a string in characters:
x==y tests if x and y are equal (note that single = means something completely different):
Select selects elements from a list according to a criterion (EvenQ tests whether a number is even):
We’ve got to make up our own criterion for Select. To do that, we use a pure function, indicated by # and &:
Find the palindromes of English:
Find palindromes with all letters made lowercase:
Make a word all lowercase:
Make a word all uppercase:
Sort by string length:
Sort a list of words alphabetically:
Sort a list of words by length: