isEmpty

Summary

Checks if the dictionary is empty.

Usage

public bool isEmpty()

Returns

true if the dictionary is empty and false if it is not.

Description

Checks if the dictionary is empty (has no keys/values).

Examples

Basic Usage
1
2
3
4
5
6
7
import System;
 
Dictionary<int> empty = {};
Dictionary<int> notEmpty = { a: 1 };
 
Console.log(empty.isEmpty());    // true
Console.log(notEmpty.isEmpty()); // false

Share

HTML | BBCode | Direct Link