Tap here to switch tabs
Problem
Submissions

Problem: Construct K Palindrome Strings

Construct K Palindrome Strings asks whether every character in a given string can be used to form exactly k palindrome strings, with no characters left over.

Statement

Given a string s and an integer k, return true if all the characters in s can be used to construct k palindrome strings, or false otherwise.

Note: A palindrome is a string that reads the same forward and backward.

Constraints:

  • 1≤1 \leq s.length ≤105\leq 10^5

  • s consists of lowercase English letters.

  • 1≤1 \leq k ≤105\leq 10^5

⋮
Tap here to switch tabs
Problem
Submissions

Problem: Construct K Palindrome Strings

Construct K Palindrome Strings asks whether every character in a given string can be used to form exactly k palindrome strings, with no characters left over.

Statement

Given a string s and an integer k, return true if all the characters in s can be used to construct k palindrome strings, or false otherwise.

Note: A palindrome is a string that reads the same forward and backward.

Constraints:

  • 1≤1 \leq s.length ≤105\leq 10^5

  • s consists of lowercase English letters.

  • 1≤1 \leq k ≤105\leq 10^5