How do I get every word from a string?

Hello fellow robloxians!

Hey I wanted to know how to get every
word from a string, for example:
"Hey I’m funnyfunns! "

word1: Hey
word2: I’m:
word3: funnyfunns

or something like that.

Any help will help.

          Farewell, Goodbye, Peace

If you use the lua built in string.split method it will give you a table containing each word and their position as the indexes in the table.

do you want to find a string?


I used to know that. But over time I forgot. Thanks for remindng me.

No ofc I dont! i dont wanna find a string. ofc not! why would i have event comented xd

No problem! If this post helped you just be sure to mark it as a solution so other users can find help from this post! Best, Boston.

Yes i already put it as the solution

Here is the API Reference for string if you ever forget a function.

Thank you also. Will be useful when I need it. Thanks.

1 Like