Day 3: Try, Catch, and Finally
Problem Link
Solution
if (typeof s === "string") {
console.log(
s
.split("")
.reverse()
.join("")
);
} else {
console.log("s.split is not a function" + "\n" + s);
}
Last updated
Was this helpful?