Solved


Triangle Numbers Below N
This is an offshoot of <http://www.mathworks.com/matlabcentral/cody/problems/5-triangle-numbers Cody Problem 5: Triangle Numbers...

3 days ago

Solved


Replace secondary diagonal elements of a square array
Replace all the secondary diagonal elements of the square array A with the number n Example: A = [1 2 3 4 5 6 ...

3 days ago

Solved


Create a matrix X, where each column is a shifted copy of the vector v
Example : in->v = (1:5)'; 1 2 3 4 5 out-> [1 5 4 3 2;2 1 5 4 3;3 2 1 5 4;4 3 2 1 5;5 4 3 ...

3 days ago

Solved


Return fibonacci sequence do not use loop and condition version 2
Calculate the nth Fibonacci number,return sequence Given n, return f where f = fib(n) and f(1) = 1, f(2) = 1, f(3) = 2, ... ...

3 days ago

Solved


Find the maximum two numbers of every column of a matrix
Find the maximum two numbers of every column of a matrix. Example: If we input a matrix A = [ 1 2 4 6 0 3 ...

3 days ago

Solved


Test if a Number is a Palindrome without using any String Operations
*Description* Given an integer _X_, determine if it is a palindrome number. That is, _X_ is equal to the _X_ with the digits ...

3 days ago

Solved


vector to string
Determine what the ASCII characters spell out. Example: input = [ 72 73 71 72] output = 'HIGH'

3 days ago

Solved


Largest Prime Number
Given a matrix X, find the largest prime number in X.

3 days ago

Solved


union without repitition
Let a = [9 9 9 9 9 9 8 8 8 8 7 7 7 6 6 6 5 5 4 2 1] b = [1 1 1 3 3 3 3 3 4 4 4 4 4 10 10 10] Output should be [9 8...

3 days ago

Solved


most frequent character
Obtain the most frequent character. For example, s='balaram'; output='a'; If there is a tie between letters, return t...

3 days ago

Solved


Alternately upper-lower case
Modify the string to alternate between upper and lower case. For example, s='achyuta' output='AcHyUtA' Update - Test case...

3 days ago

Solved


Given a number N, find the smallest prime P>N
Given a number N, find the smallest prime P greater than N. For example: If N=10 then P=11. If N=13 then P=17.

3 days ago

Solved


How many digits are there?
Input(s) - any string Output(n) - number of digits within string s

3 days ago

Solved


Too Many Zeros, Dump Them!
Sometimes when I create a matrix, I use this syntax: a = zeros(1000,1000); But when the function ends, I find that I don'...

3 days ago

Solved


N-Queens Checker
Picture a chessboard populated with a number of queens (i.e. pieces that can move like a queen in chess). The board is a matrix,...

3 days ago

Solved


calculate the tangent of angle in radians
Calculate the tangent of angle in degrees

3 days ago

Solved


Calculate the base-10 logarithm of a number
Calculate the logarithm of number x

3 days ago

Solved


Determine if a row vector has NaN
Determine if a row vector x has NaN

3 days ago

Solved


Test if a number is numeric or not
Test if a number is numeric or not

3 days ago

Solved


Find the minimum element of the matrix
Example: If x = [3 9; 5 2] then y = 2

3 days ago

Solved


find the roots of a quadratic equation
for e.g x = [ 2 -1 -3] y = [1.5 -1]

3 days ago

Solved


ASCii Code
Using Matlab get the ASCii for '?'

3 days ago

Solved


Determine the roots of a cubic equation
Given the coefficients a, b, c, and d of a cubic equation, a*x^3 + b*x^2 + c*x + d = 0, determine its roots.

3 days ago

Solved


Nth root
Nth root of a number x

3 days ago

Solved


Kinetic Energy
Given mass, m, and kinetic energy, KE, find the velocity of the object.

3 days ago

Solved


free points
function y = your_fcn_name(x) y = x(1)+x(2); end

3 days ago

Solved


Distance walked 3D
suppose you go from x-y-z coordinates [3,4,2] to [0,0,2] to [0,1,2] to [1,1,2], to [1,1,20] then you walked 25 units of distance...

3 days ago

Solved


Enlarge array
Given an m-by-n numeric array (A) and a 1-by-2 vector (sz) indicating the dimensions [p q] to enlarge each element, return an (m...

3 days ago

Solved


Clock Hand Angle 1
Given a time in HH:MM:SS, find the smallest angle (in degrees) between the hour and minute hand

3 days ago

Solved


Van Eck's Sequence's nth member
Return the Van Eck's Sequence's nth member. For detailed info : <http://oeis.org/A181391 OEIS link> and <https://www.theguard...

3 days ago

Load more