已解决


Divisible by 2
This is the first problem in a set of "divisible by x" problems. You will be provided a number as a string and the function you ...

7 years 前

已解决


Saving MATLAB session to a file
How to save MATLAB session to a file?

7 years 前

已解决


Create a Matrix of Zeros
Given an input x, create a square matrix y of zeros with x rows and x columns.

7 years 前

已解决


Back to basics 9 - Indexed References
Covering some basic topics I haven't seen elsewhere on Cody. Given an input matrix and row and column, output the index of th...

7 years 前

已解决


Complex number
For complex number c=a+bi, write code that will add a and b together.

7 years 前

已解决


Divisible by 21
Write a function to determine if a number is divisible by 21.

7 years 前

已解决


The great 82-year-old
Let's answer the question below; 'I am *x* years old and I have never written programs. If I study from now, will I be able ...

7 years 前

已解决


Vectorize the digits of an Integer
Create a vector of length N for an integer of N digits. x = 123045; x_vec = [1 2 3 0 4 5]; I happened upon a trick ...

7 years 前

已解决


Calculate the volume of the cube.
Example n = 3; a=volume(n); a = 27

7 years 前

已解决


ASCii Code
Using matlab, give the symbol that is associated with ASCii code 122

7 years 前

提问


(Anti)diagonal automation
Counting from the top right element to the the bottom left element of an indicative 5x5 matrix, is there a quick way to automate...

7 years 前 | 1 个回答 | 0

1

个回答

已解决


Max of a Vector
Write a function to return the max of a vector

7 years 前

已解决


Count photos
Given n people, everyone must have pictures taken with everyone, each photo includes only two persons, please count the total nu...

7 years 前

已解决


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

7 years 前

已解决


Back to basics 3 - Temp Directory
Covering some basic topics I haven't seen elsewhere on Cody. Return a string that is the path to the system's current temp di...

7 years 前

已解决


Given area find sides
In a right angle triangle given area 'A' one arm=x, another arm=2x then find the value of x. For example, area A=400 then ...

7 years 前

已解决


Make a random, non-repeating vector.
This is a basic MATLAB operation. It is for instructional purposes. --- If you want to get a random permutation of integer...

7 years 前

已解决


Make an awesome ramp for a tiny motorcycle stuntman
Okay, given a vector, say v=[1 3 6 9 11], turn it into a matrix 'ramp' like so: m=[1 3 6 9 11; 3 6 9 11 0; 6 9 ...

7 years 前

已解决


Back to basics 4 - Search Path
Covering some basic topics I haven't seen elsewhere on Cody. Return a string that is the user's portion of the current search...

7 years 前

已解决


Generate this matrix
For a given odd integer n, generate a matrix as follows: Input: n = 5; Output: [ 2 1 0 0 0 1 ...

7 years 前

已解决


Split a given string from the first instance of a given character
A simple operation to split a given string into two substrings at the point where the desired character is first found. e.g. ...

7 years 前

提问


How to remove non consecutive values from a vector?
I have the following vector that represents how many times consecutive values appear in a row by using the following code: ...

7 years 前 | 1 个回答 | 0

1

个回答

已解决


Project Euler: Problem 6, Natural numbers, squares and sums.
The sum of the squares of the first ten natural numbers is, 1^2 + 2^2 + ... + 10^2 = 385 The square of the sum of the first ...

7 years 前

已解决


Maximum value in a matrix
Find the maximum value in the given matrix. For example, if A = [1 2 3; 4 7 8; 0 9 1]; then the answer is 9.

7 years 前

已解决


Negative matrix
Change the sign of all elements in given matrix.

7 years 前

已解决


Y=X
Given an input variable x, output a variable y that is equal in value to x. Example: Input x = 1 Output y is 1 Inp...

7 years 前

已解决


Matlab Basics - Rounding I
Write a script to round x DOWN to the next lowest integer: e.g. x = 2.3 --> x = 2 also: x = 2.7 --> x = 2

7 years 前

已解决


Make a list string
Given a cell string, produce a string separating the items with spaces and commas and with an 'and' preceding the final item, an...

7 years 前

已解决


Compare two input matrices
Check which input matrix has more elements. Return "1" if matrix A has more elements than matrix B. Otherwise return "0". Exa...

7 years 前

已解决


Sum of series I
What is the sum of the following sequence: Σ(2k-1) for k=1...n for different n?

7 years 前

加载更多