All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars
 perplexus dot info

 Permutations count (Posted on 2015-10-01)
Find the number of permutations of (1,2,3...n) possessing the following feature:

The number n is the only local maximum e.g. 123465, 123564, 654321,
as opposed to 651432, 261354.

 See The Solution Submitted by Ady TZIDON Rating: 3.0000 (1 votes)

Comments: ( Back to comment list | You must be logged in to post comments.)
 I guess simplicity is in the mind of the user | Comment 4 of 10 |
(In reply to Simpler solution by Jer)

One method uses the binary of whether any given number comes before or after the maximum; the other uses whether the next n gets added just before or just after the old maximum. Both seem equally simple to me.
 Posted by Charlie on 2015-10-02 09:57:08

Please log in:
 Login: Password: Remember me: Sign up! | Forgot password

 Search: Search body:
Forums (4)
Newest Problems
Random Problem
FAQ | About This Site
Site Statistics
New Comments (1)
Unsolved Problems
Top Rated Problems
This month's top
Most Commented On

Chatterbox:
Copyright © 2002 - 2019 by Animus Pactum Consulting. All rights reserved. Privacy Information