Risolto


square of a number
find square of a given number

oltre 4 anni fa

Risolto


Find the index of elements in a string vector
In the vector of v, find the index of elements specified by a. v = ["Lion","Koara","Elephant","Snake","Dog","Cat","Camel"]; ...

oltre 4 anni fa

Risolto


Split array into pieces according to corresponding array
An array x of length n has values 1...m with each value appearing at least once. The values are sorted (n>=m). A second...

oltre 4 anni fa

Risolto


Replace values out of an interval with the lower or upper values
For a vector or matrix X and an interval [n1,n2], the function replace every element of x inferior to n1 by n1, and every elemen...

oltre 4 anni fa

Risolto


Coin Tossing: Probability of Same Heads for N tosses
A pair of physicists toss a coin n times each. What is the probability that they tossed the same number of heads? *Input:*...

oltre 4 anni fa

Risolto


Electrical Diode Current Calculation
In engineering, there is not always a single equation that describes a phenomenon accurately enough to be applied in all instanc...

oltre 4 anni fa

Risolto


Castling-03
Given the position of different chess pieces on the chessboard, figure out whether castling is valid or not in the next move (wh...

oltre 4 anni fa

Problema


Castling-03
Given the position of different chess pieces on the chessboard, figure out whether castling is valid or not in the next move (wh...

oltre 4 anni fa | 1 | 7 risolutori

Risolto


Castling-02
This is a follow up of problem <https://www.mathworks.com/matlabcentral/cody/groups/1/problems/45329-castling-01> Given...

oltre 4 anni fa

Problema


Castling-02
This is a follow up of problem <https://www.mathworks.com/matlabcentral/cody/groups/1/problems/45329-castling-01> Given...

oltre 4 anni fa | 1 | 7 risolutori

Risolto


Castling-01
Given the position of only player's chess pieces(some of them) on the chessboard, figure out whether castling is valid or not. ...

oltre 4 anni fa

Problema


Castling-01
Given the position of only one player's chess pieces(some of them) on the chessboard, figure out whether castling is valid or no...

oltre 4 anni fa | 1 | 12 risolutori

Risolto


Procrustean bed
Given a vector x and an integer n, convert x to a vector of length n by (1) chopping off the end if it is too long, or (2) addin...

oltre 4 anni fa

Risolto


Convolution Power
Create the convolution-power vector from initial vector _x_ and power _n_. In other words, similar to the scalar case, raising ...

oltre 4 anni fa

Risolto


How many rectangles in a grid ?
How many rectangles are there in an m × n grid ? For example, if m=1 & n=2, we have 3 rectangles.

oltre 4 anni fa

Risolto


rectangle in circle
In the figure below, the rectangle at the corner measures a cm x b cm. What is the radius of the circle in cm? <<http://www....

oltre 4 anni fa

Risolto


Rotate it!
Given a set of points, your aim is to rotate it by a given angle "theta" CCW (in 2d). The points are given in a matrix(x) of dim...

oltre 4 anni fa

Risolto


CONVERT TAN TO SIN
In a right angle triangle ABC given the tan(A) then find sin(A) For example tan(A)=3/4 then sin(A)=3/5

oltre 4 anni fa

Risolto


number of groups
In a classroom, *n* students work on a special project and the other students work in groups of five. If there are 18 students i...

oltre 4 anni fa

Risolto


Find my secret function I
If give my function a x value it will give me a y value, so find the secret of it: Examples: input x=[2 5 6 8 9] ---- >>> o...

oltre 4 anni fa

Risolto


Relation between functions "dec2bin" & "dec2binvec"
Here it's an easy problem we try to find the relation between the two functions "dec2bin" & "dec2binvec", so here you must write...

oltre 4 anni fa

Risolto


Cody Matlab Version
What is the current Cody Matlab Release? *Output:* string *Examples:* '(R2012a)' or 'R2012a' Hint: We have mo...

oltre 4 anni fa

Risolto


Volume of a sphere given its surface area
You just measured its surface area, that is the input.

oltre 4 anni fa

Risolto


Create incremental spiral WITHOUT USING EVAL or FEVAL
Constructions that use feval or eval are used to cheat with cody. This test-suite tries to avoid that trick. The goal of this...

oltre 4 anni fa

Risolto


leap year
find the number of leap years within the given time interval

oltre 4 anni fa

Problema


leap year
find the number of leap years within the given time interval

oltre 4 anni fa | 1 | 61 risolutori

Risolto


Leap Year
According to Gregorian Calender(which is in use now, in many countries),decide whether a given year is a leap year or not. Give...

oltre 4 anni fa

Risolto


Formatting currency numbers
Given a number, format it properly for textual display using the notation $xxx,xxx,xxx.xx. Assume that no more than two digits ...

oltre 4 anni fa

Risolto


Find the nearest prime
Given a positive integer 'n', the task is to find a prime number greater than or equal to 'n'. Example 1 If given 'n' is ...

oltre 4 anni fa

Risolto


Keep Only the Upper characters in a string
Keep Only the Upper characters in a string s = 'Sreeram Mohan'; output = SM;

oltre 4 anni fa

Carica altro