> For the complete documentation index, see [llms.txt](https://trizen.gitbook.io/sidef-lang/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://trizen.gitbook.io/sidef-lang/programming_tasks/e/empty_string.md).

# Empty string

Create an empty string:

```ruby
var s = "";
var s = String.new;
```

These expressions all evaluate to true to determine emptiness:

```ruby
s == "";
s.length == 0;
s.is_empty;
s ~~ /^\z/;
s ~~ /\A\z/;
```

Non-empty expressions, in addition to simply negating the above expressions:

```ruby
s != "";
s.length > 0;
s ~~ /./s;
s !~ /^\z/;
```
