← All problems

Valid Anagram

easy

Given two strings s and t, return true if t is an anagram of s — the same letters, the same number of times, in any order.

Example

Input: s = "anagram", t = "nagaram"
Output: true

Input: s = "rat", t = "car"
Output: false
Loading...