Code Directory
 Visual Basic & VB.NET
New Code
.Net VCL for Delphi
ASP. NET C# PDF Software 4.5
LinqConnect Professional 4.8
CAD VCL: 2D/3D CAD in Delphi/C++Builder 14
wolfSSL 3.15.7
AnyStock Stock and Financial JS Charts 8.4.2
ODBC Driver for SQLite 2.4
dotConnect for SugarCRM 1.7
dbForge SQL Complete 5.9
dbForge Studio for MySQL 8.0
.Net Runtime Library for Delphi
Scimbo 1.64
AnyMap JS Maps 8.4.2
GetOrgChart 2.5.3
Top Code
Issue Manager App 1.0
Skincare Management System 1.4
Ticket Booking System 1.0
Hotel Management - Full Board Version 6.55
Simple Hill-Climbing 1.0
.Net VCL for Delphi
MCU 8051 IDE 1.4.7
CPP-2-HTML CSS Source Code Tagger 1.02
Clustering results measurement 1.0
MLM Forced Matrix Plan Software 1.0.2
GNU Common C 2.3.2
College Management System Script 1.0.4
Online Vacation Rental Booking Website Script 4.3.0
Naive Bayes Classifier 1.0
Library Management System 1.0
Top Rated
Paste phpSoftPro 1.4.1
Deals and Discounts Website Script 1.0.2
ADO.NET Provider for ExactTarget 1.0
Solid File System OS edition 5.1
Classified Ad Lister 1.0
Aglowsoft SQL Query Tools 8.2
ICPennyBid Penny Auction Script 4.0
PHP Review Script 1.0
ATN Resume Finder 2.0
ATN Site Builder 3.0
Availability Booking Calendar PHP 1.0
PHP GZ Blog Script 1.1
ATN Jobs Software 4.0
ATN Mall 2.0
WeBuilder 2015 13.3
Getting <n>th permutation of a sequence 
File ID: 66739

Getting <n>th permutation of a sequence 
Download Getting <n>th permutation of a sequence Error Link
License: Freeware
Downloads: 5
Submit Rating:
Getting <n>th permutation of a sequence  Description
Description: This function, given a sequence and a number n as parameters, returns the <n>th permutation of the sequence (always as a list).

License: Freeware

Related: Algorithms


Downloads: 5

More Similar Code

Small function to generate every permutation of a given sequence. Works for lists and strings

This very simple function computes the n n-th roots of a given complex number. The attained complex roots can be plotted on a polar diagram.
It is more performante then
roots([1, zeros(1,n-1), -x]),
since it is based on very simple...

This function returns N point DFT samples of 2dw band of Fourier transform of a sequence. Typically, fft() returns N samples of Fourier transform ranging from 0 to 2pi. This function takes the N-point DFT samples and returns N-point samples...

Usage :
r = subfactorial(n) calculates the subfactorial of a non -negative integer (n) using the inclusion-exclusion principle.
The subfactorial can be written as,
!n = n! sum( (-1)^k / k! ), for k = 0 to n
!n :...

To quickly find the index of the first maximum item of a sequence.

This generator will sort only the requested part of a list. Useful for getting just the first few elements of a list and avoiding the overhead of sorting the whole thing.

While I have seen many permutation recipes on this site, there seems to be no recipe yet which shows how to generate the permutations of a "bag". A bag is like a set but can contain elements more than once.

n the bottom of a Stefan tube there is a quiescent liquid with a mixture of acetone (component 1) and methanol (component 2). Vapor that evaporates from this pool of liquid diffuses to the top of the tube. Air (component 3) keeps the mole...

It is very fast and simple file to display histogram of a 3D image
imhist3(I,n) n is the number of bins in the histogram
imhist3(X,map) X isindexed 3D image and map is colormap map

The following function creates a map of all members of a class, navigating ALL of the base classes in the correct order. This can be used for various purposes, like checking whether a certain method is defined anywhere in a class hierarchy.

User Review for Getting <n>th permutation of a sequence
- required fields

Please enter text on the image