Pastebin
API
tools
faq
paste
Login
Sign up
SHARE
TWEET
Censored Words JS Fundamentals
TZinovieva
Mar 6th, 2023
179
0
Never
Add comment
Not a member of Pastebin yet?
Sign Up
, it unlocks many cool features!
JavaScript
0.20 KB
| None
|
0
0
raw
download
clone
embed
print
report
function
censoredWords
(
text
,
word
)
{
while
(
text.
includes
(
word
)
)
{
let newWord
=
(
'*'
.
repeat
(
word.
length
)
)
;
text
=
text.
replace
(
word
,
newWord
)
;
}
console.
log
(
text
)
;
}
Advertisement
Add Comment
Please,
Sign In
to add comment
Public Pastes
✅ Make $1500 in 20 minutes
JavaScript | 2 sec ago | 0.32 KB
⭐Crypto Exchange Profit Method⭐ 9
JavaScript | 7 sec ago | 0.32 KB
Profit Method
Java | 8 sec ago | 0.08 KB
MAKE $9OO INSTANTLY D M
Java | 8 sec ago | 0.08 KB
✅ MAKE $500 IN 15 MIN
JavaScript | 11 sec ago | 0.32 KB
MAKE $500 IN 15 MIN
Java | 12 sec ago | 0.09 KB
MAKE $900 INSTANTLY
Java | 21 sec ago | 0.08 KB
Swapzone Glitch ⭐Working⭐
JavaScript | 23 sec ago | 0.32 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!