Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

5
LINES

< > BotCompany Repo | #42 // reverse

Lua code

t = {}
for i = #input, 1, -1 do
  table.insert(t, input:sub(i, i))
end
return table.concat(t, "")

Author comment

reverses the input string

test run  test run with input  download  show line numbers   

Relations

Travelled to 12 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt

Comments [hide]

ID Author/Program Comment Date
696 #1000610 Edit suggestion:
!636
!629

main {
static Object androidContext;
static String programID;

public static void main(String[] args) throws Exception {
t = {}
for i = #input, 1, -1 do
table.insert(t, input:sub(i, i))
end
return table.concat(t, "")
}}
2015-08-19 09:28:48  delete 
694 #1000604 (pitcher) 2015-08-20 15:28:24

add comment

Image recognition results

Recognizer Recognition Result Visualize Recalc
#308 101 [visualize]

Snippet ID: #42
Snippet name: reverse
Eternal ID of this version: #42/1
Text MD5: bf6e3fc4f5bb7ef96cfd06788cdeb9d5
Author: stefan
Category: text transformations
Type: Lua code
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2013-12-23 18:39:40
Source code size: 101 bytes / 5 lines
Pitched / IR pitched: Yes / Yes
Views / Downloads: 1326 / 330
Referenced in: #1028274 - style.css for NewChatBotDesign
#1028492 - style.css for ContractBox (extended with new-changes.css + progress bar + glowing)
#1028652 - style.css for BookBetter
#1028951 - style.css for Exodontia
#1029323 - style.css for Infinici
#1029663 - style.css for csPILLAI
#1029713 - style.css for GAIPP Bot
#1029808 - style.css for AVOR Demonstrator
#1030233 - style.css for Gazelle Bot [now moved to https://gazelle.rocks/237267]
#1030643 - style.css for FIA Bot
#1031825 - style.css for AVOR Demonstrator 2021
#3000382 - Answer for ferdie (>> t = 1, f = 0)
#3000383 - Answer for funkoverflow (>> t=1, f=0 okay)