已解决


Who Has the Most Change?
You have a matrix for which each row is a person and the columns represent the number of quarters, nickels, dimes, and pennies t...

6 years 前

已解决


Is my wife right?
Regardless of input, output the string 'yes'.

6 years 前

已解决


Triangle Numbers
Triangle numbers are the sums of successive integers. So 6 is a triangle number because 6 = 1 + 2 + 3 which can be displa...

6 years 前

已解决


Make a checkerboard matrix
Given an integer n, make an n-by-n matrix made up of alternating ones and zeros as shown below. The a(1,1) should be 1. Examp...

6 years 前

已解决


Pizza!
Given a circular pizza with radius _z_ and thickness _a_, return the pizza's volume. [ _z_ is first input argument.] Non-scor...

6 years 前

已回答
Can someone help me filling holes in the image attached and make it a perfect binary image with all holes filled?
You might want to have a look at binary morphological operators like opening and closing: https://www.cs.auckland.ac.nz/course...

6 years 前 | 0

| 已接受

已解决


Implement a ROT13 cipher
Replace each character in string s1 with the character that is shifted 13 positions from it (wrap back to the beginning if neces...

6 years 前

已回答
How can I convert this for if loop into a while loop?
x=6*rand(1,10)+2 i = 1; while i<11 if i<5 x(i)=-1; elseif i>=5 && i<8 x(i)=1; else ...

6 years 前 | 1

| 已接受

已回答
How to round the decimal?
You might want to check out this function for that: <https://nl.mathworks.com/matlabcentral/fileexchange/26212-round-with-sig...

6 years 前 | 1

已回答
Unable to find explicit solution using solve function
You might want to have a look at the productlog function to get an analytic solution without solve. You could fill in the genera...

6 years 前 | 0

已回答
How can I get the weight of object in image ?
For that you would need to estimate the volume and know the density of the food. That doesn't really have a trivial solution.

6 years 前 | 0

已解决


Distance a ball travels after throwing vertically
Calculate the total distance *'d'* (in meters) a ball would travel after *'s'* seconds and starting velocity of *'v'* (in m/s). ...

8 years 前

已解决


Matrix of almost all zeros, except for main diagonal
Write a program to input an integer n and build a n-by-n matrix with the numbers 1,2,...,n on the main diagonal and zeros elsewh...

8 years 前

已解决


Select every other element of a vector
Write a function which returns every other element of the vector passed in. That is, it returns the all odd-numbered elements, s...

8 years 前

已解决


Add two numbers
Given a and b, return the sum a+b in c.

8 years 前

已解决


The Hitchhiker's Guide to MATLAB
Output logical "true" if the input is the answer to life, the universe and everything. Otherwise, output logical "false".

8 years 前

已解决


Find all elements less than 0 or greater than 10 and replace them with NaN
Given an input vector x, find all elements of x less than 0 or greater than 10 and replace them with NaN. Example: Input ...

8 years 前

已解决


Bottles of beer
Given an input number representing the number of bottles of beer on the wall, output how many are left if you take one down and ...

8 years 前

已解决


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

8 years 前

已解决


Most nonzero elements in row
Given the matrix a, return the index r of the row with the most nonzero elements. Assume there will always be exactly one row th...

8 years 前

已解决


Determine if input is odd
Given the input n, return true if n is odd or false if n is even.

8 years 前

已解决


Find the sum of all the numbers of the input vector
Find the sum of all the numbers of the input vector x. Examples: Input x = [1 2 3 5] Output y is 11 Input x ...

8 years 前

已解决


Make the vector [1 2 3 4 5 6 7 8 9 10]
In MATLAB, you create a vector by enclosing the elements in square brackets like so: x = [1 2 3 4] Commas are optional, s...

8 years 前

已解决


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

8 years 前