Laddar uppgiften…
Imagine you have two sets of letters and want to leave only the letters that can form the same word in a different order. Write a function make_anagram_deletions that returns the minimum number of character deletions needed to make strings a and b anagrams of each other. In one operation, you may delete one character from either string.
"cde", "abc"4"abc", "abc"0"aaa", "a"2def make_anagram_deletions(a: str, b: str) -> int:
Logga in för att se historik över inskick
Logga inLogga in för att använda AI-mentorn
Logga in"cde", "abc"4"abc", "abc"0"aaa", "a"2"", "abc"3"fcrxzwscanmligyxyvym", "jxwtrhvujlmrpdoqbisbwhmgpmeoke"30"showman", "woman"2