A résolu


String Array Basics, Part 1: Convert Cell Array to String Array; No Missing Values
<http://www.mathworks.com/help/matlab/characters-and-strings.html String array> and cell array are two types of containers for s...

plus de 2 ans il y a

A résolu


Cell Counting: How Many Draws?
You are given a cell array containing information about a number of soccer games. Each cell contains one of the following: * ...

plus de 2 ans il y a

A résolu


Remove element(s) from cell array
You can easily remove an element (or a column in any dimension) from a normal matrix, but assigning that value (or range) empty....

plus de 2 ans il y a

A résolu


Natural numbers in string form
Create a cell array of strings containing the first n natural numbers. _Slightly_ harder than it seems like it should be. Ex...

plus de 2 ans il y a

A résolu


Convert a numerical matrix into a cell array of strings
Given a numerical matrix, output a *cell array of string*. For example: if input = 1:3 output is {'1','2','3'} whic...

plus de 2 ans il y a

A résolu


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

plus de 2 ans il y a

A résolu


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

plus de 2 ans il y a

A résolu


Only once: cleaning up your columns
We have a logical array (with ones and zeroes). It is simple: after processing every column may only contain a single true value...

plus de 2 ans il y a

A résolu


Replace multiples of 5 with NaN
It is required to replace all values in a vector that are multiples of 5 with NaN. Example: input: x = [1 2 5 12 10 7] ...

plus de 2 ans il y a

A résolu


Values in Array
How many values are in the array

plus de 2 ans il y a

A résolu


Find the Best Hotels
Given three input variables: * |hotels| - a list of hotel names * |ratings| - their ratings in a city * |cutoff| - the rat...

plus de 2 ans il y a

A résolu


Square root of a number
Write a code that will output the square root of x.

plus de 2 ans il y a

A résolu


Remove the Zero
Given an array n, remove all zeros

plus de 2 ans il y a

A résolu


Times 2 - START HERE
Try out this test problem first. Given the variable x as your input, multiply it by two and put the result in y. Examples:...

plus de 2 ans il y a

A résolu


Project Euler: Problem 1, Multiples of 3 and 5
If we list all the natural numbers below 10 that are multiples of 3 or 5, we get 3, 5, 6 and 9. The sum of these multiples is 23...

plus de 2 ans il y a

A résolu


Matlab Basics II - Max & Index of Max
Write a function that takes a vector x, then returns both the max value in x and its location in the vector for example x ...

plus de 2 ans il y a

A résolu


Matlab Basics II - Extract last 3 elements of a vector
Let x be a vector of unknown length, we are always interested in the last 3 numbers in the vector, write a function that gives t...

plus de 2 ans il y a

A résolu


Variable_Addition
be able to add any variable to the number one

plus de 2 ans il y a

A résolu


Area of a Square
Given the length x of the side of a regular square, find the area of the square, A.

plus de 2 ans il y a

A résolu


Laws of motion 2

plus de 2 ans il y a

A résolu


Laws of motion 5

plus de 2 ans il y a

A résolu


Laws of motion 1

plus de 2 ans il y a

A résolu


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

plus de 2 ans il y a

A résolu


y equals x divided by 2
function y = x/2

plus de 2 ans il y a

A résolu


Try 1.5.4: Celsius to Fahrenheit
Write a program to convert an input given in Celsius to Fahrenheit. Examples: Input celsiusValue = 100 Output fahrValu...

plus de 2 ans il y a

A résolu


Matlab Basics - Absolute Value
Write a script that returns the absolute value of the elements in x e.g. x = [-1 -2 -3 -4] --> y = [1 2 3 4]

plus de 2 ans il y a

A résolu


Compute a dot product of two vectors x and y
x and y are input vectors, d is a number and contains their dot product

plus de 2 ans il y a

A résolu


radius of a spherical planet
You just measured its surface area, that is the input.

plus de 2 ans il y a

A résolu


Vector creation using colon operator
Create a vector y containing n uniformly spaced values between a and b, with a < b. Use the colon (:) operator.

plus de 2 ans il y a

A résolu


Insert zeros into vector
Insert zeros after each elements in the vector. Number of zeros is specified as the input parameter. For example: x = [1 ...

plus de 2 ans il y a

Charger plus