Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

permutations

Vašek edited this page Feb 6, 2019 · 1 revision

permutations

This function returns the number of possible permutations

Syntax:

permutations(n,x)
Argument Description
int n The number of possible numbers
int x Length of row

Returns: int

Description:

A permutation is a number of possible arranging objects in a row. Number n represents the number of objects, and number x is a length of the row.

Example :

int value = pemutations(3,3);

So, when we have numbers 1, 2 and 3 (n = 3) we can assemble them in row (x = 3) - six different ways: (1,2,3), (1,3,2), (2,1,3), (2,3,1), (3,1,2), and (3,2,1). So the output ofthis function is 6.

Back to number_functions

Clone this wiki locally

AltStyle によって変換されたページ (->オリジナル) /