- Trending Categories
- Data Structure
- Networking
- RDBMS
- Operating System
- Java
- MS Excel
- iOS
- HTML
- CSS
- Android
- Python
- C Programming
- C++
- C#
- MongoDB
- MySQL
- Javascript
- PHP
- Physics
- Chemistry
- Biology
- Mathematics
- English
- Economics
- Psychology
- Social Studies
- Fashion Studies
- Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Mukul Latiyan has Published 474 Articles
Mukul Latiyan
7K+ Views
We can append two tables together in Lua with a trivial function, but it should be noted that no library function exists for the same.There are different approaches to concatenating two tables in Lua. I’ve written two approaches that perform more or less the same when it comes to complexity.The ... Read More
Mukul Latiyan
2K+ Views
Concatenation of strings is the process in which we combine two or more strings with each other, and in most of the programming languages this can be done by making use of the assignment operator.In Lua, the assignment operator concatenation doesn’t work.ExampleConsider the example shown below − Live Demostr1 = "tutorials" ... Read More
Mukul Latiyan
5K+ Views
Handling command line arguments in Lua is one of the key features of any programming language. In Lua, the command line arguments are stored in a table named args and we can use the indices to extract any particular command line argument we require.Syntaxlua [options] [script [args]]The options are −-e ... Read More
Mukul Latiyan
2K+ Views
Lua codes are not like Python when it comes to indentation. So, most of the code you will write will work even if it falls on another line, and you don’t necessarily need to have the nested code to be intended by a certain tab size.The code indentation in lua ... Read More
Mukul Latiyan
4K+ Views
It is a general convention that the size of the array is the number of elements that are present inside the array before the nil. In many cases, nil is not allowed in the array, but for some applications, it is not an issue to have nil inside them.If we ... Read More
Mukul Latiyan
709 Views
An Embedded language is a language that can be used in an application. It is a programming language that adds an ease of performing operations in a specific application.There are many embedded languages that you can use, the most common ones are Lua, LISP, VBA etc.When it comes to choosing ... Read More
Mukul Latiyan
2K+ Views
The _tostring element in Lua receives an argument of any type and converts it to a string in a reasonable format.If the metatable of e has a "__tostring" field, then tostring calls the corresponding value with e as argument, and uses the result of the call as its result.The __tostring ... Read More
Mukul Latiyan
10K+ Views
Sometimes we want to execute the system's command and then make use of whatever was returned by them, and in order to do that we simply can either make use of the os.execute() function or io.popen() function.The difference between the os.execute() function and the io.popen() function is that the output ... Read More
Mukul Latiyan
341 Views
There are cases where we would like to implement PHP Lua extension in PHP.ini so that we can make use of Lua as an embedding language for our PHP code.It can be done with some series of steps that need to be run in a specific manner and the most ... Read More
Mukul Latiyan
1K+ Views
You might have noticed ternary operators in different programming languages, but since there’s no ternary operator in Lua, as per the official documentation, we can create one for ourselves with the help of the Lua operators.Let’s first understand what a ternary operator is and why we need one.ExampleConsider the example ... Read More