Menu

Close
  • Home
  • GitHub
  • Contacts
  • Project Euler
Subscribe
Menu

algorithm

A 4-post collection

Page 1 of 1

Merge sort - inversions count

In an array, arr = [a0, a1, …, aN-1] , the elements at indices i and j (where i < j) form an inversion if aI > aJ. In other words, inverted elements and are considered to be “out of order”. To correct an inversion, we can swap adjacent elements.

»

Mijkenator on algorithm, elixir, erlang, python, merge sort 10 December 2016

Quick sort with erlang, elixir, python

Wikipedia article about merge sort algorithm.
Source code examples on Github

»

Mijkenator on algorithm, elixir, erlang, python, merge sort 17 October 2016

Merge sort with erlang, elixir, python

Source code examples on Github Wikipedia article about merge sort algorithm.

»

Mijkenator on algorithm, elixir, erlang, python, merge sort 11 October 2016

Integer partition with python and erlang

In number theory and combinatorics, a partition of a positive integer n, also called an integer partition, is a way of writing n as a sum of positive integers. Two sums that differ only in the order of their summands are considered the same partition.

»

Mijkenator on erlang, pyhon, algorithm 29 April 2016
Page 1 of 1
Mijkenator`s blog © 2016
Casper theme powered by Ghost