function match(input, pattern) if input == nil then return false end --assert(input, "input is nil") pattern = pattern:gsub("<number>", "([0-9]+)") return input:match(pattern) end
test run test run with input download show line numbers
Travelled to 12 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Recognizer | Recognition Result | Visualize | Recalc |
---|---|---|---|
#308 | 192 | [visualize] |
Snippet ID: | #139 |
Snippet name: | match (for +15) |
Eternal ID of this version: | #139/1 |
Text MD5: | 16ac11766a7cf59009c15ac86bfc9820 |
Author: | stefan |
Category: | |
Type: | Lua code |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2014-01-13 05:08:47 |
Source code size: | 192 bytes / 6 lines |
Pitched / IR pitched: | Yes / Yes |
Views / Downloads: | 985 / 561 |
Referenced in: | #133 - +15 (pharmacokinetics t calculator) #160 - match (for database 1) #3000382 - Answer for ferdie (>> t = 1, f = 0) #3000383 - Answer for funkoverflow (>> t=1, f=0 okay) |