Solved


I Plead the Fifth
Write a function to provide a yes or no answer to the input string. However, it must plead the 5th amendment (return an empty st...

6 years ago

Solved


A matrix of introverts
You are given a matrix full of numbers who happen to be very shy. Write a MATLAB function that will put a square of zeros aroun...

6 years ago

Solved


Now 20% off!
Furloughs are hitting government workers this year. To commemorate getting one unpaid day off each week until the end of Septem...

6 years ago

Solved


Array ex-OR
There are in MATLAB logical functions such as _<http://www.mathworks.co.uk/help/matlab/ref/and.html and>,_ _<http://www.math...

6 years ago

Solved


Binary Neighbourhood
Given a natural number reorder its binary form to create another number, closest to the given one. Examples: * 1 gives 2, ...

6 years ago

Solved


Iccanobif numbers 1
There are a lot of problems in Cody that deal with Fibonacci numbers (1, 1, 2, 3, 5, 8, 13, 21 etc...) so let's turn things arou...

6 years ago

Solved


Make one vector from two others
You are given two vectors of equal length. Your task is to create a MATLAB script that will repeat all of the values in the fir...

6 years ago

Solved


Cody problems in French : Trouvez la logique Pt.2
Trouvez la logique entre x et y, aidez-vous de la test suite. Bon courage. P.S: L'utilisation de "^" est de nouveau fortement...

6 years ago

Solved


Cube root of max value in a vector
Find the cube root of the maximum value in a vector

6 years ago

Solved


Chào các bạn.
Cho 3 số. Tính tổng của chúng

6 years ago

Solved


Numbers on 7-segment
This is a 7-segment: _ |_| |_| It's a 3-by-3 char matrix.It has made by 3 characters: '_' , '|' and ' ' (space...

6 years ago

Solved


Spiral Matrix
for a given integer n>=3, generate a matrix of nxn such that the value n^2 is at bottom left and its decreasing towards center ...

6 years ago

Solved


Minefield Sonar
*Background* In mine-hunting games (e.g. Microsoft Minesweeper), the user is provided with a covered grid that, upon a left c...

6 years ago

Solved


Nilpotent matrix
Check if matrix A is <http://mathworks.com/ nilpotent>.

6 years ago

Solved


Do the lines intersect?
You are given two line segments. Do they cross? Consider one segment as (x1,y1) to (x2,y2), the other segment as (x3,y3) to (...

6 years ago

Solved


Create a "+" flag
Given two odd numbers, [m, n], return a matrix of size m x n which has all elements of the centre column and centre row set as 1...

6 years ago

Solved


Was ist denn los?
Nur für deutschsprechende Leute! Wie geht's? ...also gut, bis bald!

6 years ago

Solved


Change on Spiral Matrix
n>=3, generate a matrix of nth such that n^2 is the max number, and max number must be in [1,1] or [end, end]. One example will ...

6 years ago

Solved


The maximum sum of squares (testing)
Create a function file with an input maxval to determine the maximum number of terms for the series 1^2 + 2^2 + 3^2 + ... such t...

6 years ago

Solved


Find the missing numbers.
Total *N* numbers are in the series of natural numbers ( *1,2,3,...,N* ). The input is an array (unsorted) of those natural num...

6 years ago

Solved


generate number in particular way
A = [1 5 2 7]; MAX = 10; generate a array Y = [1 2 2 2 2 2 3 3 4 4]; i.e. total eleme...

6 years ago

Solved


Detect pair of equal values in a Matrix
A 2D matrix of 2 rows and N columns with random integer numbers. A = [3 1 2 4 6 6 7; 7 3 2 1 5 2 4] ...

6 years ago

Solved


Divisible by n, prime divisors (including powers)
For this problem, you will be provided an array of numbers (not necessarily in order). Return the array of numbers with only pri...

6 years ago

Solved


Divisible by n, prime vs. composite divisors
In general, there are two types of divisibility checks; the first involves composite divisors and the second prime divisors, inc...

6 years ago

Solved


Divisible by 16
Write a function to determine if a number is divisible by 16. This can be done by a few different methods. Here are two: # If...

6 years ago

Solved


Count from 0 to N^M in base N.
Return an array of numbers which (effectively) count from 0 to N^M-1 in base N. The result should be returned in a matrix, with ...

6 years ago

Solved


Set defaults
Write a function that computes the volume of a cube. The function should be able to accept three inputs: the length, width, and...

6 years ago

Solved


count to vector
Return a matrix of numbers of dimension K by N, where K = prod(v), and N=length(v). The rows count from a vector of ones up to v...

6 years ago

Solved


Is the paranthesis sequence balanced ?
Quantum mechanics and computer science are interested in <http://en.wikipedia.org/wiki/Bra%E2%80%93ket_notation bra-kets>. Today...

6 years ago

Solved


How long do each of the stages of the rocket take to burn?
A space rocket has 3 stages: - stage 1, s1; - stage 2, s2; - stage 3, s3. If s1 burns 3 x as long as s2 which burns ...

6 years ago

Load more