Resuelto


Balanced number
Given a positive integer find whether it is a balanced number. For a balanced number the sum of first half of digits is equal to...

casi 10 años hace

Resuelto


Quote Doubler
Given a string s1, find all occurrences of the single quote character and replace them with two occurrences of the single quote ...

casi 10 años hace

Resuelto


Given a window, how many subsets of a vector sum positive
Given a vector: [1 0 -1 3 2 -3 1] and a window of 2, A sliding window would find: 1 + 0 = 1 0 - 1 = -1 ...

casi 10 años hace

Resuelto


Indexed Probability Table
This question was inspired by a Stack Overflow question forwarded to me by Matt Simoneau. Given a vector x, make an indexed pro...

casi 10 años hace

Respondida
How to create a standalone application of a script that calls "sim" function ?
To create a standalone from a Simulink model, you will need the <mathworks.com/products/simulink-coder/ Simulink Coder>. I don't...

casi 10 años hace | 0

Respondida
conversion of daily cell into monthly cell.
Use vertical concatenation. month = [day1; day2; day3; ...; day31]; % day1 through day31 would be the variables containing ...

casi 10 años hace | 0

Respondida
Getting error while plotting a 2d countour
In a GUI created in GUIDE, you may have to specify the axes in which to create the contour. contour(handles.axesName, x, y, ...

casi 10 años hace | 0

Resuelto


First N Perfect Squares
*Description* Return the first N perfect squares *Example* input = 4; output = [ 1 4 9 16 ];

casi 10 años hace

Resuelto


Right and wrong
Given a vector of lengths [a b c], determines whether a triangle with those sides lengths is a right triangle: <http://en.wikipe...

casi 10 años hace

Resuelto


Length of the hypotenuse
Given short sides of lengths a and b, calculate the length c of the hypotenuse of the right-angled triangle. <<http://upload....

casi 10 años hace

Resuelto


inner product of two vectors
inner product of two vectors

casi 10 años hace

Resuelto


Counting Money
Add the numbers given in the cell array of strings. The strings represent amounts of money using this notation: $99,999.99. E...

casi 10 años hace

Resuelto


Replace NaNs with the number that appears to its left in the row.
Replace NaNs with the number that appears to its left in the row. If there are more than one consecutive NaNs, they should all ...

casi 10 años hace

Resuelto


Pangrams!
A pangram, or holoalphabetic sentence, is a sentence using every letter of the alphabet at least once. Example: Input s ...

casi 10 años hace

Resuelto


Simple equation: Annual salary
Given an hourly wage, compute an annual salary by multiplying the wage times 40 and times 50, because salary = wage x 40 hours/w...

casi 10 años hace

Resuelto


Find the longest sequence of 1's in a binary sequence.
Given a string such as s = '011110010000000100010111' find the length of the longest string of consecutive 1's. In this examp...

casi 10 años hace

Resuelto


Find the alphabetic word product
If the input string s is a word like 'hello', then the output word product p is a number based on the correspondence a=1, b=2, ....

casi 10 años hace

Resuelto


Sort a list of complex numbers based on far they are from the origin.
Given a list of complex numbers z, return a list zSorted such that the numbers that are farthest from the origin (0+0i) appear f...

casi 10 años hace

Resuelto


Summing digits
Given n, find the sum of the digits that make up 2^n. Example: Input n = 7 Output b = 11 since 2^7 = 128, and 1 + ...

casi 10 años hace

Resuelto


Weighted average
Given two lists of numbers, determine the weighted average. Example [1 2 3] and [10 15 20] should result in 33.333...

casi 10 años hace

Resuelto


Fibonacci sequence
Calculate the nth Fibonacci number. Given n, return f where f = fib(n) and f(1) = 1, f(2) = 1, f(3) = 2, ... Examples: Inpu...

casi 10 años hace

Respondida
Will you show me examples of changing time zones with datetime?
Setting the TimeZone property doesn't change the time of a datetime vector, it just tells Matlab which time zone the datetime ob...

casi 10 años hace | 1

Respondida
How to overlay plots one above the other?
Set the 'Clipping' property of what you want outside the axes to off. <https://de.mathworks.com/help/matlab/examples/clipping...

casi 10 años hace | 1

Respondida
Invalid Message ID Format. Is my syntax wrong?
You do not need message() for that function. function area = areaof3ang(x1,y1,x2,y2,x3,y3) if nargin~=6 % this is...

casi 10 años hace | 0

| aceptada

Respondida
How to force output of large figure to not be "scaled", or how to properly print a pdf whose dimensions won't fit on the [small] screen
I haven't exported to PDF, but I used to have similar problems when exporting figures to emf. I have a short script that fixes ...

casi 10 años hace | 0

Resuelto


Back to basics 8 - Matrix Diagonals
Covering some basic topics I haven't seen elsewhere on Cody. Given an input vector of numbers, output a square array with the...

casi 10 años hace

Problema


pizza deals
Given two pizza slices of different sizes: * Slice A with angle alpha1, radius r1 and price p1 * Slice B with angle alpha2, ...

casi 10 años hace | 2 | 43 solvers

Respondida
How to get 1807 point data array to 1806 data array?
The second input must be a vector, not the size of the output. So if you want to interpolate between the points, use something l...

casi 10 años hace | 0

Respondida
can't use the help docements about matlab2015a
It sounds like a currupt Matlab installation. I would suggest you reinstall Matlab and if the problem still persists, call the M...

casi 10 años hace | 0

| aceptada

Respondida
How do I write a matlab code that requests the user for an array of integers and stores that array into the variable called A. How do I determine whether the integer is odd or even.
doc input Will tell you how to get user input. doc mod could be useful for finding out if a number is odd or even.

casi 10 años hace | 0

Cargar más