Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

check if string is empty

let str1 = "Hello world!";
let str2 = "";
let str3 = 4;
console.log(str1.length === 0)
console.log(str2.length === 0)
console.log(str3.length === 0)

false
true
false
Source by www.delftstack.com #
 
PREVIOUS NEXT
Tagged: #check #string #empty
ADD COMMENT
Topic
Name
3+2 =