Skip to content

Conversation

@rxiddhi
Copy link
Contributor

@rxiddhi rxiddhi commented Oct 27, 2025

Problem:
You are given an array nums consisting of distinct integers, and an integer k.
Your task is to generate all possible permutations of length k using the elements of nums.
Each element can be used at most once in each permutation.
Return all such permutations in any order.

Output:
Return all such permutations in any order.

Constraints:
1≤n,k≤8
−50≤nums[i]≤50

Problem:
You are given an array nums consisting of distinct integers, and an integer k.

Your task is to generate all possible permutations of length k using the elements of nums.

Each element can be used at most once in each permutation.

Return all such permutations in any order.

Output:
Return all such permutations in any order.

Constraints:
1≤n,k≤8
−50≤nums[i]≤50
@ghostmkg ghostmkg merged commit e9996dc into ghostmkg:main Oct 28, 2025
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants