解決済み


How many complete pizzas (number 2)
x is a vector with numbers of pizza slices. A corresponding vector n indicates in how many slices the pizza slices of x were cut...

9年以上 前

解決済み


How many complete pizzas
x is a vector with numbers of pizza slices. A corresponding vector n indicates in how many slices the pizza slices of x were cut...

9年以上 前

解決済み


Find Pseudo-Cyclic Number
A cyclic number is an integer in which cyclic permutations of the digits are successive multiples of the number https://en.wikip...

9年以上 前

解決済み


time difference
The arrays x and y contain time values in the form of: x = [hours minutes seconds] Create the output z which contains the...

9年以上 前

解決済み


Remove multiples of N
in the vector x remove all multiples of N. x = [1 2 3 4 5 6]; N = 2; Then y = [1 3 5];

9年以上 前

解決済み


Determinate if day D is a date that occurs during Daylight Saving Time in Italy
<https://en.wikipedia.org/wiki/Summer_Time_in_Europe>

9年以上 前

解決済み


How many hours are there in a day in Italy?
Remember "European Summer Time"

9年以上 前

解決済み


Calculate solution of given polynomial
For example, y=function([3 -2 -4]) In here, input vector indicate 3*x^2-2*x-4, y is solution of former equation. y=[1.5...

9年以上 前

解決済み


Bubble sort
Write your own bubble sort function ( <https://en.wikipedia.org/wiki/Bubble_sort>) to sort all elements in x in ascending order....

9年以上 前

解決済み


Probabilities - More brains than luck
This problem is related to problem <http://it.mathworks.com/matlabcentral/cody/problems/596-more-luck-than-brains> where the te...

9年以上 前

解決済み


extract part elements of matrix into one new matrix
Given a matrix, includes different elements(plus, minus and zero), extract the nonzero elements and form a new matrix. for examp...

9年以上 前

解決済み


Mersenne Primes vs. All Primes
A Mersenne prime (M) is a prime number of the form M = 2^p - 1, where p is another prime number. <https://www.mathworks.com/matl...

9年以上 前

解決済み


Numbers at bit-boundary
Find if a number is on or below the bit-boundary, as defined below. Examples 7,9 straddle the bit-boundary at 2^3 as do 31...

9年以上 前

解決済み


Distance of the centroids of the balls
Given *n* balls of radius *r* and the vector *p (nx3)* with all position *(x,y,z)* of the balls, return the symmetric matrix *A ...

9年以上 前

解決済み


The Ulam Matrix
The Ulam spiral is simple to describe. On a gridded piece of paper, write down the number 1. Then write successive integers as y...

9年以上 前

解決済み


Calculate the h-index
H-index is a powerful tool for quantifying the scientific contribution of a researcher. H-index is defined as follows (source - ...

9年以上 前

解決済み


Avengers Assemble!
Given matrix with so many zeroes, trim those zeroes and output a matrix joining all nnz elements Example: input = [0 0 0 0 0...

9年以上 前

解決済み


MiniMax
Find the smallest value in array, which is the maximum of its row and column. Example: in array shown below are two numbers w...

9年以上 前

解決済み


Return a list sorted by number of consecutive occurrences
Inspired by Problem 38 by Cody Team. Given a vector x, return a vector y of the values in x sorted by the number of CONSECUTIVE...

9年以上 前

解決済み


Neither minima nor maxima
Input v is a vector. Return all the elements of v which are not a local minimum or maximum. Example: v = [1 2 3 4 5] Ou...

9年以上 前

解決済み


De-primed
Write a function that will multiply every prime number in the array or matrix by two, leaving all other numbers the same, and re...

9年以上 前

解決済み


Factorions: Numbers that equal the sum of the factorials of their digits
From Wikipedia: _A factorion is a natural number that equals the sum of the factorials of its decimal digits_ For example: ...

9年以上 前

解決済み


Beads on a Necklace (Convex Hulls)
We may describe a <http://en.wikipedia.org/wiki/Convex_hull convex hull> as a rubber band stretched around a list of points. Som...

9年以上 前

解決済み


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...

9年以上 前

解決済み


Find smallest integer type to accommodate your number
MATLAB supports 1-, 2-, 4-, and 8-byte storage for integer data. Find the smallest integer type to accomodate a scalar integer. ...

9年以上 前

解決済み


Implement simple rotation cypher
If given a letter from the set: [abc...xyz] and a shift, implement a shift cypher. Example: 'abc' with a shi...

9年以上 前

解決済み


Spherical radius given four points
Determine the radius of a sphere provided four non-coplanar points on the surface of the sphere. pts = [x1 y1 z1; x...

9年以上 前

解決済み


old wine in a new bottle?
* You have been given an apparently brand new unary function XXX, * that maps some ordinary scalars to scalars, * please gues...

9年以上 前

解決済み


Clean the List of Names
Given a list of names in a cell array, remove any duplications that result from different capitalizations of the same string. So...

9年以上 前

解決済み


Return the circumference and area of a circle with radius r
Write a function to calculate the circumference and area of a circle with radius r.

9年以上 前

さらに読み込む