What method is used to extract a part of a string from index 0 to index 4 (excluded)?
const str = "abcdef";
All are correct
str.slice(0, 4)
str.substring(0, 4)
str.substr(0, 4)