BackmediumUncategorized uncategorized medium

Character Distribution Equivalence Solution

Problem Statement

Given two strings `source` and `target`, determine if they contain the same characters, where the frequency of each character in `source` must be equal to its frequency in `target`, without considering the order of characters.

Example 1
Input
{"source":"listen","target":"silent"}
Output
true
Live Compiler
Loading...
Test Cases & Output
🔒 Sign up to run your code

🚀 Practice this problem

Run code, get AI hints & track streak

Sign Up Free