Moduli number system in Kotlin
The challenge
A number system with moduli is defined by a vector of k moduli, [m1,m2, ···,mk].
The moduli must be pairwise co-prime, which means that, …
In-depth guides, insights, and best practices for modern software engineering
A number system with moduli is defined by a vector of k moduli, [m1,m2, ···,mk].
The moduli must be pairwise co-prime, which means that, …
Given an array X of positive integers, its elements are to be transformed by running the following operation on them as many times as …
Read Article →Given
I = [l, u) (l is in interval I but u is not) l and u being floating numbers (0 <= l < u),Create an NxN multiplication table, of size provided in parameter.
for example, when given size is 3:
1 2 3
2 4 6
3 6 9
for given …
Read Article →Complete the solution so that it strips all text that follows any of a set of comment markers passed in. Any whitespace at the end of …
Read Article →Consider the sequence S(n, z) = (1 - z)(z + z**2 + z**3 + ... + z**n) where z is a complex number and n a positive integer (n > 0). …
Percona has a great toolkit that allows you to perform schema changes on a MySQL or MariaDB database without any downtime, it works by creating a new …
Read Article →Let us consider this example (array written in general format):
ls = [0, 1, 3, 6, 10]
Its following parts:
ls = [0, 1, 3, 6, 10]
ls = …
Read Article →
In mathematics, a Diophantine equation is a polynomial equation, usually with two or more unknowns, such that only the integer solutions …!-->!-->
Read Article →Write a function that accepts two square matrices (N x N two dimensional arrays), and return the sum of the two. Both matrices being …
The number 81 has a special property, a certain power of the sum of its digits is equal to 81 (nine squared). Eighty one (81), is the …
Read Article →You have to give the number of different integer triangles with one angle of 120 degrees which perimeters are under or equal a certain …
Read Article →