Gelöst


Number of divisors of a given number
Given a Number n, return the number of his divisors without listing them example: n=14 ; Divisors={1,7,2,14} ; y=4 n=...

mehr als 10 Jahre vor

Gelöst


Find the right x in a 1. order Polynomal (y = m*x+c)
Given two points in a Cartesian coordinate system, find the x-value, where polynomial of 1. order (y = m*x+c) is equal to a giv...

mehr als 10 Jahre vor

Gelöst


Accessing values in a cell
You are given c, which is a 1xN cell array, and a and b, which are each two 1xM vectors. Your job is to give the bth value in t...

mehr als 10 Jahre vor

Gelöst


Full combinations
Given n input vectors x1, x2, …, xn, generate a p*n matrix y whose rows contain all element-wise combinations of the vectors x1,...

mehr als 10 Jahre vor

Gelöst


How many ways to write a number
Given two positive numbers n and k, where n>=k.In how many ways can we write n as sum of k positive numbers.Same numbers but dif...

mehr als 10 Jahre vor

Gelöst


the "power matrix" of two vetcors
Given two row vectors x,y of lengths m and n (resp.), create an m x n matrix whose i,j entry is x(i)^y(j).

mehr als 10 Jahre vor

Gelöst


Raise a polynomial to a power
In Matlab, polynomials are represented by a vector of coefficients. For example, the polynomial p=a*x^2 + b*x + c is represente...

mehr als 10 Jahre vor

Gelöst


GJam March 2016 IOW: Clock Dance
This Challenge is derived from <http://code.google.com/codejam/contest/8274486/dashboard#s=p1 GJam March 2016 Annual I/O for Wom...

mehr als 10 Jahre vor

Gelöst


Zelda - Rupee Count (Item Purchase)
Building off of <https://www.mathworks.com/matlabcentral/cody/problems/3025-zelda-rupee-count Problem 3025>, suppose that an arr...

mehr als 10 Jahre vor

Gelöst


Zelda - Rupee Count (Compact)
Building off of <https://www.mathworks.com/matlabcentral/cody/problems/3025-zelda-rupee-count Problem 3025>, suppose that Link's...

mehr als 10 Jahre vor

Gelöst


Zelda - Rupee Count
Rupees are the main currency in The Legend of Zelda games. The value of each rupee is determined by its color. Unfortunately, th...

mehr als 10 Jahre vor

Gelöst


Letter and word frequency
Here is a task: You’re given a text file. Your first task is to create a variable in MATLAB which will hold the text given to...

mehr als 10 Jahre vor

Gelöst


Net Present Value of a Stream of Cash Flows
Calculate <https://en.wikipedia.org/wiki/Present_value the net present value of a future cash flow> vector given; * future ca...

mehr als 10 Jahre vor

Gelöst


Create array of all Distances between two Sets of Points
This Challenge is a subsection of <http://www.mathworks.com/matlabcentral/cody/problems/1110-usc-fall-2012-acm-martian-pranks Ma...

mehr als 10 Jahre vor

Gelöst


GJam 2014 China Rd B: Sudoku Checker
This Challenge is derived from <http://code.google.com/codejam/contest/2929486/dashboard#s=p0 GJam 2014 China Sudoku>. Large Cas...

mehr als 10 Jahre vor

Gelöst


Fletcher-Reeves Conjugate Gradient Method
Write a function to find the values of a design variable vector, _x_, that minimizes an unconstrained scalar objective function,...

mehr als 10 Jahre vor

Gelöst


Create formatted value string Cell array of a vector
This Challenge is to create a cell array that contains strings of vector components in a given format. c=vector2formattedstri...

mehr als 10 Jahre vor

Gelöst


GJam March 2016 IOW: Cody's Jams
This Challenge is derived from <http://code.google.com/codejam/contest/8274486/dashboard GJam March 2016 Annual I/O for Women Co...

mehr als 10 Jahre vor

Gelöst


Unique: Faster for options 'rows' and 'stable' for large array of uint8
Challenge: Execute unique(a,'rows','stable') Faster for 'a' being uint8. The "unique" function for the 'rows' and 'stable' o...

mehr als 10 Jahre vor

Gelöst


Big numbers, least significant digits
Given two numbers, x and n, return the last d digits of the number that is calculated by x^n. In all cases, d will be the number...

mehr als 10 Jahre vor

Gelöst


Tribute to Ramanujan
The nth taxicab number, denoted as T(n), is defined as the smallest number that can be expressed as a sum of two positive algebr...

mehr als 10 Jahre vor

Gelöst


Mystery problem
Given integer x between 1 and 50, return integer y=mystery(x), where mystery(1) = 111 mystery(6) = 809 ... mystery...

mehr als 10 Jahre vor

Gelöst


Go-style solver
Consider a variation of the game Go where one player has gone ahead and placed several pieces all at once. Assuming that the sec...

mehr als 10 Jahre vor

Gelöst


Bleed non-zeros to the right using REGEXP, and that sort of cheatcodess...
This one is quite similar to <http://www.mathworks.nl/matlabcentral/cody/problems/1998-bleed-non-zeros-to-the-right>. But thi...

mehr als 10 Jahre vor

Gelöst


Functional inputs
Return an n-dimensional array whose elements are the results of a function over a set of vectors. The (i,j,k, ...n)th element...

mehr als 10 Jahre vor

Gelöst


Is 3D point set Co-Planar?
This Challenge is to determine if four 3D integer points are co-planar. Given a 4x3 matrix representing four x,y,z integer poin...

mehr als 10 Jahre vor

Gelöst


Placing Beads Neatly in a Box
You are given a string of n black and white beads. Your job is to pack them neatly into a square box. "Neatly" in this case mean...

mehr als 10 Jahre vor

Gelöst


Fun with a compass
Each night for the past week, you have been having the same nightmare: You find yourself back in your junior high school geometr...

mehr als 10 Jahre vor

Gelöst


Is my wife really right?
For every input, output the string 'yes' once. Example: [yes1, yes2] = YesSheIs('Am I right?', 'Do you love me?') yes1 = '...

mehr als 10 Jahre vor

Gelöst


Fill the Matrix - 2
Input is a column vector and n. n columns will be added to the left of the input column. The first value of the row is the me...

mehr als 10 Jahre vor

Mehr laden