+ 3

Python in javascript

Hey Help me! In python for getting word from list we should use : Y=list[0] But in javascript what should we use Like, I want to get words bern 3-6 But how In py I should use : list[3:6] How in javascript? Here, Suppose list=["🙈","🙊","🙉","🙉",] I want to replace from this so I can use re=replace(list[0:],"5,) And I will get list=["🙈","5","5","5"] Here is code where I want to replace the inappropriate words from string.. https://code.sololearn.com/WTg1khwEvt0z/?ref=app

30th Sep 2020, 10:04 AM
Shubham Ingale
Shubham Ingale - avatar
2 Answers
+ 4
console.log(list.slice(3,6))
30th Sep 2020, 10:11 AM
Abhay
Abhay - avatar
+ 1
Use Py.js (Developed By Me) Try It Here: https://code.sololearn.com/W7V9YKg5IZlW/?ref=app
14th Oct 2021, 2:56 AM
Sancho Godinho
Sancho Godinho - avatar