Jump to content

read function has second argument.

  • You cannot reply to this topic
No replies to this topic

#1 BigSHinyToys

  • Members
  • 1,001 posts

Posted 28 May 2013 - 09:58 AM

The read function in the wiki doesn't specify the second argument you can input to it. This argument is a table that contains strings theses strings will are then used with the up / down keys in the shell for example to select a input that was made previously.

local tLast = {}
while true do
    local input = read(nil,tLast)
    tLast[#tLast + 1] = input

1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users