QUOTE(curioComp @ 12 Nov, 2009 - 10:58 AM)

Than you! It was very helpfull, but actually, the third element in my sentences are always numbers, but this:
CODE
getLastWord = last . words
It's not good for numbers, just for words...
Is it posible to write something like this?
CODE
getLastWord = last . numbers
Thank you so much in advance.
As long as the number is separated from the second and forth word by a space, like so: "word1 word2 3 word4", the 'words' function will work. What the 'words' function does is split up a string at every space, and eliminates the space. The word function will work just fine for you.
CODE
words "word1 word2 3 word4 word5" -- This returns ["word1","word2","3","word4","word5"]
On an unrelated note, I would really appreciate it if you could click the "this post was helpful" link on any of my posts that you find helpful. You don't have to, but it would be really awesome if you did!

Good luck.
This post has been edited by Raynes: 12 Nov, 2009 - 05:19 PM