Pastebin
API
tools
faq
paste
Login
Sign up
SHARE
TWEET
Untitled
a guest
Oct 23rd, 2018
82
0
Never
Add comment
Not a member of Pastebin yet?
Sign Up
, it unlocks many cool features!
text
0.16 KB
| None
|
0
0
raw
download
clone
embed
print
report
function func(s, a, b) {
for (let i = s.length - 1; i >= 0; i--) {
if (s.substring(i, i + 1) === a || (s.substring(i, i + 1) === b)) return i;
}
return -1;
}
Add Comment
Please,
Sign In
to add comment
Public Pastes
new Earthquake shell script
Bash | 5 min ago | 0.39 KB
cc-ftp
Lua | 6 min ago | 4.24 KB
SNN
Python | 14 min ago | 7.73 KB
ftp.lua
Lua | 14 min ago | 4.58 KB
SNN-RandomForest
Python | 15 min ago | 9.88 KB
CNN-RNN
Python | 17 min ago | 4.03 KB
🤑 G2A.com Free Gift Card Guide Apr 2024 FIX 🤑
GetText | 19 min ago | 0.39 KB
cc-ftp
Lua | 19 min ago | 4.58 KB
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the
Cookies Policy
.
OK, I Understand
Not a member of Pastebin yet?
Sign Up
, it unlocks many cool features!