Advanced “Hello World!” in Lua

I started learning Lua today. It’s used to script extensions and automations in the Moho animation software I’m considering. Since I forgot my earbuds, I wasn’t going to be able to watch my video lessons at the coworking space, so I decided to explore Lua as I’m also trying to get my teenager to learn it for Roblox.

Since I’m an experienced developer, just doing “Hello World!” wasn’t going to be enough, so I wrote a console script that asks your name, gets it from the console input, and then repeats it 10 times (to try their way of looping). I commented it heavily not for you, but for my reference when I come back to it. But I thought I’d share.

A good deal of it is me noting the differences between it and JavaScript, like mentioning function hoisting. Hope you find it useful.

Add a Comment

Your email address will not be published. Required fields are marked *