Resuelto


Reepeating numbers in array
Repeating numbers in array In = [1 0 0 0 2 0 0 0 3 0 0 0 0 0 5 0 0 0 0]. Out = [1 1 1 1 2 2 2 2 3 3 3 3 3 3 5 5 5 5 5].

más de 3 años hace

Resuelto


check whether a number is a pentatope number
<https://oeis.org/A000332>

más de 3 años hace

Resuelto


generate nth pentatope number
https://en.wikipedia.org/wiki/Pentatope_number

más de 3 años hace

Resuelto


remove numbers from a string
check the given string for any numbers.in case one is found,remove it.but the two portions should be separated. if more than one...

más de 3 años hace

Resuelto


Repeat elements of a vector
Repeat each elements of a given vector according to their values. * x=[1,2,1,3] * y=[1,2,2,1,3,3,3]

más de 3 años hace

Resuelto


Double Factorial
Return double factorial n(n-2)...(5)(3)(1), n>0, odd n!! = n(n-2)...(6)(4)(2), n>0, even 1 ...

más de 3 años hace

Resuelto


factorial
calculate x!

más de 3 años hace

Resuelto


The length of the equal sides of an isoceles triangle is 'a'.For all the possible (integer) values of the remaining side,find the associated angles between the two equal sides.
the remaining side may have many possible values.only assume integer ones for simplicity.

más de 3 años hace

Resuelto


An n-sided regular polygon is drawn within a circle whose radius is 'r', what will be the area of the polygon?
area of a polygon is p*a/2. where, p is the perimeter and a is the apothem i.e. the normal distance from center to any of the si...

más de 3 años hace

Resuelto


Summing Rows and Columns
Create a matrix y of size (n+1) whose last column's elements are the summation of the elements of all the other columns and last...

más de 3 años hace

Resuelto


Cross ("+") flag returns
Given two numbers, [m, n], return a matrix of size m x n which has all elements of the centre column and centre row set as 1, an...

más de 3 años hace

Resuelto


Create a "+" flag
Given two odd numbers, [m, n], return a matrix of size m x n which has all elements of the centre column and centre row set as 1...

más de 3 años hace

Resuelto


Sum Sum Sum!
Calculate the sum of the natural numbers from 1 to n

más de 3 años hace

Resuelto


SAY 'OHYEAH'
Regardless of input, output the string 'OHYEAH'.

más de 3 años hace

Resuelto


Chào các bạn.
Cho 3 số. Tính tổng của chúng

más de 3 años hace

Resuelto


Vogel-Dobbener entropy
*Vogel-Dobbener entropy* is a measure of dispersion for ordinal variables. Given an ordered list of distinct observations u_...

más de 3 años hace

Resuelto


Square root of number
Square root of given number.

más de 3 años hace

Resuelto


Efficiency of a single phase Transformer
Calculate the efficiency of a single phase transformer whose KVA rating is A KVA, loading factor x,power factor p,full load copp...

más de 3 años hace

Resuelto


Ratio between sum of primes and sum of factors
Write a function that calculates the ratio between the sum of primes numbers lower or equal to x, and the sum of the factors of ...

más de 3 años hace

Resuelto


Ratio between sums of prime and non-prime numbers
Write a function that calculates the ratio between the sum of the prime numbers lower or equal than x, and the sum of the non-pr...

más de 3 años hace

Resuelto


Get the mean digit
Write a function that gives the mean digit (round towards nearest integer) of an input and positive number. For example: x ...

más de 3 años hace

Resuelto


Check if is a square
Given four coordinates, write a function to check if they form a square on the XY plane.

más de 3 años hace

Resuelto


Find the complement of a number in binary
Input x is a decimal number and output y is the complement of binary representation of x. For example, x = 10 has the binary ...

más de 3 años hace

Resuelto


Find The Difference
Vector x is given.calculate the difference between the biggest and the smallest number that we can create from elements of x. fo...

más de 3 años hace

Resuelto


Reverse the Matrix
Given a Matrix A, reverse it. Such that, last element of A becomes 1st and vice versa. for example: Input = [1 2 3;4 5 ...

más de 3 años hace

Resuelto


Dial Up
Each number on telephone keypads, except 0 and 1, corresponds to a set of uppercase letters as shown in this list: 2 ABC, 3 DEF...

más de 3 años hace

Resuelto


Minimum Maximum Sort Array
sort one array by put minimum value followed by maximum as follow a=[2 3 1 5] and the solution is y=[1 5 2 3 3 2 5 1];

más de 3 años hace

Resuelto


Find the largest number
Find the largest number |x| among 4 numbers given as variables |a|, |b|, |c|, and |d|. Example: Input: a = 4; b = 7; c ...

más de 3 años hace

Resuelto


Portfolio diversification: choose your stocks !
we have the returns of 3 stocks for the last 4 years and we have to combine only 2 stocks that are less correlated. Example: st...

más de 3 años hace

Resuelto


Simple spirometer - find your lung capacity from the number and size of soap bubbles in one breath
Assumed that each bubble has practically the same diameter d. Given total number n of bubbles. Find volume v of breath.

más de 3 años hace

Cargar más