Solved


Create a cell array out of a struct
Create a cell array out of a (single) struct with the fieldname in the first column and the value in the second column: in: ...

7 Monate ago

Solved


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

7 Monate ago

Solved


Scrabble Scores
Given a word, determine its score in <http://en.wikipedia.org/wiki/Scrabble Scrabble>. The input string will always be provi...

7 Monate ago

Solved


Summing Digits within Text
Given a string with text and digits, add all the numbers together. Examples: Input str = '4 and 20 blackbirds baked in a...

7 Monate ago

Solved


Tic Tac Toe FTW
Given a tic tac toe board: * 1 represents X * 0 represents empty. * -1 represents O It is X's move. If there is an imme...

7 Monate ago

Solved


Pattern matching
Given a matrix, m-by-n, find all the rows that have the same "increase, decrease, or stay same" pattern going across the columns...

7 Monate ago

Solved


The Goldbach Conjecture
The <http://en.wikipedia.org/wiki/Goldbach's_conjecture Goldbach conjecture> asserts that every even integer greater than 2 can ...

7 Monate ago

Solved


Find state names that end with the letter A
Given a list of US states, remove all the states that end with the letter A. Example: Input s1 = 'Alabama Montana Nebras...

7 Monate ago

Solved


Elapsed Time
Given two date strings d1 and d2 of the form yyyy/mm/dd HH:MM:SS (assume hours HH is in 24 hour mode), determine how much time, ...

7 Monate ago

Solved


Encode Roman Numerals
Create a function taking a non-negative integer as its parameter and returning a string containing the Roman Numeral representat...

7 Monate ago

Solved


The Goldbach Conjecture, Part 2
The <http://en.wikipedia.org/wiki/Goldbach's_conjecture Goldbach conjecture> asserts that every even integer greater than 2 can ...

7 Monate ago

Solved


Word Counting and Indexing
You are given a list of strings, each being a list of words divided by spaces. Break the strings into words, then return a maste...

7 Monate ago

Solved


Find the two-word state names
Given a list of states, remove all the states that have two-word names. If s1 = 'Alabama Montana North Carolina Vermont N...

7 Monate ago

Solved


Kaprekar Steps
6174 is the <http://en.wikipedia.org/wiki/6174_%28number%29 Kaprekar constant>. All natural numbers less than 10,000 (except som...

7 Monate ago

Solved


Vector creation
Create a vector using square brackets going from 1 to the given value x in steps on 1. Hint: use increment.

7 Monate ago

Solved


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

7 Monate ago

Solved


Create a vector
Create a vector from 0 to n by intervals of 2.

7 Monate ago

Solved


Flip the vector from right to left
Flip the vector from right to left. Examples x=[1:5], then y=[5 4 3 2 1] x=[1 4 6], then y=[6 4 1]; Request not ...

7 Monate ago

Solved


Whether the input is vector?
Given the input x, return 1 if x is vector or else 0.

7 Monate ago

Solved


Find max
Find the maximum value of a given vector or matrix.

7 Monate ago

Solved


Get the length of a given vector
Given a vector x, the output y should equal the length of x.

7 Monate ago

Solved


Inner product of two vectors
Find the inner product of two vectors.

7 Monate ago

Solved


Arrange Vector in descending order
If x=[0,3,4,2,1] then y=[4,3,2,1,0]

7 Monate ago

Solved


Project Euler: Problem 2, Sum of even Fibonacci
Each new term in the Fibonacci sequence is generated by adding the previous two terms. By starting with 1 and 2, the first 10 te...

7 Monate ago

Answered
snapshot problem in video processing
snapshot() is intended for use with a cameraboard object or webcam object and you are attempting you input an image object. You...

7 Monate ago | 0

Solved


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 Monate ago

Answered
How to graph data in cells?
Your data has an empty cell in it so the first step here is to remove that ToBeGraphed(cellfun(@isempty,ToBeGraphed))=[]; % rem...

7 Monate ago | 0

| accepted

Answered
Extract subset of time-curves from a 4D volume
I can reduce this to a single for loop which iterates through the timesteps but i'm not sure about doing this entirely without l...

7 Monate ago | 0

| accepted

Answered
Sum of elements in an array over x
a = [0.023 0.056 0.053 0.034 0.021 0.075 0.088]; result = sum(a(a>0.05))

7 Monate ago | 1

| accepted

Answered
Building a matrix inside a for loop
You could do it as follows: xlsData = xlsread('PartS_all.xlsx'); partID = xlsData(:,4); uPartID = unique(partID).'; % Unique ...

8 Monate ago | 0

| accepted

Load more