[go: nahoru, domu]

Skip to content

Given list of int determines number of possible permutations

Notifications You must be signed in to change notification settings

jasont14/PermutationPairs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

PermutationPairs

Determine the number of possible permutations given an array 'A' consisting of integers where each integer occurs at most 2-times (Pair) and a[n] - a[n-1] != 0.

Input Format

The first line contains a single integer denoting the number of queries.

The subsequent lines describe each query in the following form: The first line contains an integer denoting the number of elements in array . The second line contains space-separated integers describing the respective values of 'A'.

2 <- Denotes number of queries

4 <- Denotes number of elements in query. This is query 1 of 2.

1 1 2 2 < - Denotes space separated integers

2 < - Denotes number of elements in query. This is query 2 of 2.

1 2 < - Denotes space separated integers

About

Given list of int determines number of possible permutations

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages