Solved


Summation of array
Given an array, Find the sum of all of the elements in it Examples: Input x = [1 2 3 5; 4 5 6 7]; Output y is 33

9 years ago

Solved


Rounding off numbers to n decimals
Inspired by a mistake in one of the problems I created, I created this problem where you have to round off a floating point numb...

9 years ago

Problem


Solve system of equation!
Solve provided system of equation, and find x and y. 2*x+1*y=3 1*x+1*y=2 (hint: use inverse matrix)

9 years ago | 0 | 63 solvers

Problem


Find x in provided equation!
x^2-2*x+1=0 What is x? (hint: use "roots")

9 years ago | 1 | 120 solvers

Solved


Get all corner elements from a matrix where dimension of matrix is always equal to or greater than 2.
if a given matrix a = [1 2 3;4 5 6]; so answer is going to be [1 3;4 6]

9 years ago

Solved


Divisible by 2
This is the first problem in a set of "divisible by x" problems. You will be provided a number as a string and the function you ...

9 years ago

Solved


Mysterious digits operation (easy)
What is this digit operation? 0 -> 0 1 -> 9 121 -> 9 44 -> 6 15 -> 5 1243 -> 7 ...

9 years ago

Solved


Diagonal & Anti-Diagonal Matrix: Easy
Create a matrix as shown below from "magic" square. For example: if input x=9;then use mgic(x) and create the matrix...

9 years ago

Solved


Generate the Matrix!
Given n, generate the following matrix: a = [ n n-1 n-2 ... 2 1; n-1 n-1 n-2 ... 2 1; n-2 n-2 n-2 ... 2 1;...

9 years ago

Solved


Find number of days
The input is two date in string format (dd-mm-yyyy) find out the number of days between these two dates. Example: input: ...

9 years ago

Solved


What percentage?
Calculate the output c as the percentage of a on b for given a and b.

9 years ago

Solved


Reverse the input
Given an input (n), produce an output in the reverse order with out using string variables or string function. Example x ...

9 years ago

Solved


Concatenate strings
concatenate a variable number of input strings to produce one outputstring

9 years ago

Solved


Split a string into chunks of specified length
Given a string and a vector of integers, break the string into chunks whose lengths are given by the elements of the vector. Ex...

9 years ago

Solved


Vectorizing, too easy or too hard?
Please insert a . before any ^, * or / in the string. That's it!!

9 years ago

Solved


Finding perimeter of a rectangle
A rectangle has a length of x centimeters and a width of w centimeters. Find the perimeter.

9 years ago

Solved


How many jokers?
* Given DNA codes of a group of suspects, * and a code for certain types of jokers, * Count how many jokers of that type. * ...

9 years ago

Solved


Find the logic
There exists one logic in between input and output. Find it (easy math). Example 1: x=13 then y=339; Example 2: x=26...

9 years ago

Solved


Back to basics 18 - justification
Covering some basic topics I haven't seen elsewhere on Cody. Given a string with extra spaces in front and/or in back, return...

9 years ago

Solved


Make a vector of prime numbers
Input(n) - length of vector with prime numbers Output(v) - vector of prime numbers Example: * n=1; v=2 * n=3; v=[2 3 5...

9 years ago

Solved


Remove and Sort
Given a randomized array n, sort it and remove all odd integers. n=5 y = [2 4]

9 years ago

Solved


Given a matrix, return the last eigen value
Given a matrix, return the first eigen value For example: x = magic(5) 17 24 1 8 15 23 5 7 14 ...

9 years ago

Solved


frame of the matrix
Given the matrix M, return M without the external frame.

9 years ago

Solved


Inverse of Hilbert matrix
Given a non-negative integer x, return the element-wise power of 2 of the inverse of Hilbert matrix.

9 years ago

Solved


Center of mass
Given a matrix M(m,n), where m is the number of vertices of the geometrical element and n is 2 or 3 (2D-plane figure or 3D-solid...

9 years ago

Solved


Array of Ones
Create a 100 X 100 array of ones.

9 years ago

Solved


Volume of this donut
Given hole diameter a, and outermost diameter b, determine the volume y of the resulting donut.

9 years ago

Solved


Create incrementing array
Given a and b generate an output matrix as shown in following examples: a=2 b=5 output=[2 20 200 2000 20000] a=4 b...

9 years ago

Solved


random picture with random colours
write a function which creates a random(x,y) matrix with random RGB colours for example create_pic(5,5) gives us a 3d matrix. ...

9 years ago

Solved


find radius of cone
if Slant height of Cone(I)& hight of Cone(H) given then find radius of the Cone(R) for example I=5,h=4 then the ans R=3;

9 years ago

Load more