解決済み


Determine value using Look-up table method
Given a set of 2 vectors x and y related in a certain way, you are supposed to find value of y (ydash) given a particular value ...

12年以上 前

解決済み


Array GCD
* Find Greatest Common Divisor in a given array * Function Template: function ans = arraygcd(a) % a=[45 15 200 ...

12年以上 前

解決済み


Vector LCM
* Find Least Common Multiple of a given vector. * Need general solution as the test suite will be expanded. * Function Templa...

12年以上 前

解決済み


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

12年以上 前

解決済み


Remove all the consonants
Remove all the consonants in the given phrase. Example: Input s1 = 'Jack and Jill went up the hill'; Output s2 is 'a ...

12年以上 前

解決済み


Cell joiner
You are given a cell array of strings and a string delimiter. You need to produce one string which is composed of each string fr...

12年以上 前

解決済み


Replace all zeros and NaNs in a matrix with the string 'error'
Given a numeric input matrix A, possibly containing some zero values and some NaNs, replace any occurrences of zero or NaN with ...

12年以上 前

解決済み


Replace May with April
For instance, if the input is input_str = 'The flowers may bloom in April'; then the output is output_str = 'The flo...

12年以上 前

解決済み


Detect a number and replace with two NaN's
Write code which replaces the number 1 with two NaNs. Example X = [ 1 2 NaN 4 1 3 7 NaN 1 4 NaN 2] ...

12年以上 前

解決済み


Square wave average calculation
Given its peak and duty cycle, calculate avg value of square wave

12年以上 前

解決済み


Calculating Sign Changes in a Row Vector(No Element Is Zero)?
For a row vector V=[7 1 2 -3] has one sign change from 2 to -3. So N=Sign_Changes(V) must return N=1; V=[5 9 -2 7]; h...

12年以上 前

解決済み


Frobenius Norm
Write your own version of Frobenius Norm without using the 'norm' function.

12年以上 前

解決済み


Sum the elements in either diagonal of a square matrix
Sum the elements of a square matrix that lie on either the major diagonal or anti-diagonal.

12年以上 前

解決済み


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

12年以上 前

解決済み


Rotate input square matrix 90 degrees CCW without rot90
Rotate input matrix (which will be square) 90 degrees counter-clockwise without using rot90,flipud,fliplr, or flipdim (or eval)....

12年以上 前

解決済み


Binary Coder
Take an input number and print the binary value of this number.

12年以上 前

解決済み


Create a Multiplication table matrix...
Create a product table in this format: P = [ 1 2 3 4 5; 2 4 6 8 10; 3 6 9 12 15; 4 8 12 1...

12年以上 前

解決済み


Generate pi using logarithm
Generate pi using logarithm

12年以上 前

解決済み


Find nearest prime number less than input number
Find nearest prime number less than input number . For example: if the input number is 125, then the nearest prime number whi...

12年以上 前

解決済み


Temperature conversion
Convert temperature in degrees Celsius (C) to temperature in degrees Kelvin (K). Assume your answer is rounded to the nearest Ke...

12年以上 前

解決済み


Who has power to do everything in this world?
There is only one person who is older than this universe. He is Indian version of Chuck Norris.

12年以上 前

解決済み


Doubling elements in a vector
Given the vector A, return B in which all numbers in A are doubling. So for: A = [ 1 5 8 ] then B = [ 1 1 5 ...

12年以上 前

解決済み


Alternating sum
Given vector x, calculate the alternating sum y = x(1) - x(2) + x(3) - x(4) + ...

12年以上 前

解決済み


Find the nearest integer
Given a vector of integers and a real number find the closest integer. EX: >> a = [2 4 5 6 8 10]; >> b = 4.6; >> nea...

12年以上 前

解決済み


Fahrenheit to Celsius converter
Convert Fahrenheit to Celsius degrees.

12年以上 前

解決済み


Solve the set of simultaneous linear equations
Given this pair of simultaneous linear equations: 2x + 3y = 23 3x + 4y = 32 Find the solution set (x,y)

12年以上 前

解決済み


Celsius to Fahrenheit converter
Convert Celsius to Fahrenheit degrees.

12年以上 前

解決済み


Find the "ordinary" or Euclidean distance between A and Z
A, B and Z define three points in the 3D _Euclidean_ space of the form: A = [x1;y1;0]; B = [x2;y2;0]; Z = [x2;y2;z]; Find th...

12年以上 前

解決済み


Find out missing number from a vector of 9 elements
You are given a vector of size 9, x = [x1 x2 x3 x4 x5 x6 x7 x8 x9] Elements of x may be randomly selected without repeati...

12年以上 前

解決済み


Create matrix of replicated elements
Given an input element x, and the dimensions, (m, n) return a matrix of size m x n filled with element x. Example: Input: ...

12年以上 前

さらに読み込む