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

1
LINES

< > BotCompany Repo | #3000150 // Answer for therightman

New Tinybrain snippet

["", "import", " ", "re", "\n\n//just for the test\n\n", "def", " ", "match", "", "(", "", "text", "", ")", "", ":", "\n    ", "replies", " ", "=", " ", "{", "\n            ", "'k'", "", ":", " ", "'not k, ok! at least that :angry:'", "", ",", "\n            ", "'hi'", "", ":", " ", "'Hey there!'", "", ",", "\n            ", "'hey'", "", ":", " ", "'Hey, what'", "", "s", " ", "up", "", "?", "", "',\n            '", "", "bye", "", "': '", "", "Goodbye", " ", ":", "", "simple_smile", "", ":", "", "',\n            '", "", "jk", "", "': '", "", "You", "", "'re joking?'", "", ",", "\n            ", "'no'", "", ":", " ", "'NOOO??'", "\n    ", "}", "\n\n    ", "if", " ", "len", "", "(", "", "re", "", ".", "", "findall", "", "(", "", "'^nosways(.*?)'", "", ",", " ", "text", "", ")", "", ")", " ", ">", " ", "0", "", ":", "\n        ", "print", "", "(", "", "str", "", "(", "", "re", "", ".", "", "findall", "", "(", "", "'^nosways(.+)'", "", ",", " ", "text", "", ")", "", ")", "", ")", "\n        ", "return", " ", "str", "", "(", "", "'yes way '", " ", "+", " ", "re", "", ".", "", "findall", "", "(", "", "'^nosways(.+)'", "", ",", " ", "text", "", ")", "", "[", "", "0", "", "]", "", ")", "\n\n    ", "commands", " ", "=", " ", "{", "\n            ", "'current replies'", "", ":", " ", "str", "", "(", "", "'```'", " ", "+", " ", "str", "", "(", "", "replies", "", ")", " ", "+", " ", "'```'", "", ")", "\n    ", "}", "\n    ", "if", " ", "text", "", ".", "", "lower", "", "(", "", ")", " ", "in", " ", "list", "", "(", "", "replies", "", ".", "", "keys", "", "(", "", ")", "", ")", "", ":", "\n        ", "return", " ", "replies", "", "[", "", "text", "", ".", "", "lower", "", "(", "", ")", "", "]", "\n    ", "elif", " ", "text", "", ".", "", "lower", "", "(", "", ")", " ", "in", " ", "list", " ", "(", "", "commands", "", ".", "", "keys", "", "(", "", ")", "", ")", "", ":", "\n        ", "return", " ", "commands", "", "[", "", "text", "", ".", "", "lower", "", "(", "", ")", "", "]", "\n"]

download  show line numbers   

Snippet is not live.

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

No comments. add comment

Snippet ID: #3000150
Snippet name: Answer for therightman
Eternal ID of this version: #3000150/1
Text MD5: 4c02cda7a6e721f7d5c000317566a09e
Author: someone
Category:
Type: New Tinybrain snippet
Gummipassword: eleutheria-for-user
Uploaded from IP: 69.10.46.185
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2016-01-04 15:17:55
Source code size: 2003 bytes / 1 line
Pitched / IR pitched: No / Yes
Views / Downloads: 460 / 102
Referenced in: [show references]