Solved


Odd times even numbers in a matrix
First count the number of odd numbers in x, then the number of even. Return their product. example: x = [1 2] One odd ...

8 years ago

Solved


Persistence will help you solve almost any problem.
Create a function without inputs that adds one to the output every time it is called. a = counterfun; disp(a) >> 1 ...

8 years ago

Solved


Calculate geostrophic current
eta0=0.01; R=300; f=0.01; g=9.81; x=-500:50:500; y=-500:50:500; [x y]=meshgrid(x,y); eta=eta0*exp(-(x.^2+...

8 years ago

Solved


Subtract integers and add doubles
Create a function that subtracts a from b if a and b are integers and adds them if they are floats.

8 years ago

Solved


Bubble sort
Write your own bubble sort function ( <https://en.wikipedia.org/wiki/Bubble_sort>) to sort all elements in x in ascending order....

8 years ago

Solved


Determinate if day D is a date that occurs during Daylight Saving Time in Italy
<https://en.wikipedia.org/wiki/Summer_Time_in_Europe>

8 years ago

Solved


How many hours are there in a day in Italy?
Remember "European Summer Time"

8 years ago

Solved


Extract part elements of matrix into one new matrix
Given a matrix that includes different nonzero and zero entries, extract the nonzero elements and form a new matrix. The new mat...

8 years ago

Solved


Return strings encapsulated by braces
Return all substrings that are contained within braces ({}). For example: str = 'x = rho*x{-1} + (1-rho)*y{+1}'; when...

8 years ago

Solved


Sample from random roulette
Given a list of values and their probabilities sample 10,000 values. Example: x = [1 2 3 4 5]; prob = [0.2 0.1 0.4 0....

8 years ago

Solved


Namespace
Create a set of n variable names 'a_1',...,'a_n' The result should be a column oriented cell array of strings. Example inp...

8 years ago

Solved


make histogram
You probably know the function hist(x,n) to get the histogram. Now try to write the function yourself! For the cheaters wanti...

8 years ago

Solved


microseconds passed today
Calculate the amount of microseconds passed for a given date string. Return the value, rounded to the nearest integer, as a stri...

8 years ago

Solved


time of day
Calculate the time of day in days, hours, minutes or seconds passed since the beginning of the day, depending on the unit. The u...

8 years ago

Solved


Numerate input arguments
For every string input, output the corresponding number. For example: [a, b] = Test('first', 'second') a=1; b=2;

8 years ago

Solved


Calculate the eigenvalues of A.
Calculate the sum of the eigenvalues of A. If it's odd return cubed else return 54.

8 years ago

Solved


Polar Form Complex Number Entry
Write a function that takes the magnitude and angle(in degrees) of a complex number and returns a complex variable. Positive ang...

8 years ago

Solved


Number of even divisors of a given number
Given a Number n, return the number of its even divisors without listing them. example: n=14 ; EvenDivisors={2,14} ; y=2 ...

8 years ago

Solved


The last non-zero digit of a factorial
For given positive integer n, what is the last non-zero digit of n!? Example: factorial(11) = 39916800 Last non-zero d...

8 years ago

Solved


Fractal: area and perimeter of Koch snowflake
Starting from an equilateral triangle with side 's', what is the area and perimeter of Koch snowflake at n'th recursive iteratio...

8 years ago

Solved


Given n, create n random numbers such that their standard deviation is also n.
Given n, create n random numbers such that their standard deviation is also n.

8 years ago

Solved


Who have the chance?
Obtain a free 10 score in cody, if you have a chance don't change anything if you want to try or do what you can do to gain for ...

8 years ago

Solved


FloydWarshall
Our task is to find shortest paths between every pair of nodes. Floyd-Warshall is a graph algorithm for finding shortest paths i...

8 years ago

Solved


Adaptive ZigZag
Unfold a 2-D matrix to a 1-D array in Adaptive zig-zag order, e.g., for matrix [ 1 2 5 6; 3 4 7 8; 9 10 13 14; ...

8 years ago

Solved


Matrix game: Winner takes all
Given a matrix A, return a new matrix of the same size in which the biggest element of each column in A takes 1, and 0 for all t...

8 years ago

Solved


Finding operators in a MATLAB function in a string.
The aim is to find if there is an operator inside a MATLAB function call in a formula. The input is a string and the output is a...

8 years ago

Solved


Percentage profit:4
If a shopkeeper is selling W gram of salt in 1 dollar he will face r% loss. How much salt he should sell in grams to make r% pro...

8 years ago

Solved


Write a function to calculate step size delta if bits per sample and input range is given for quantization.
numBit = bits per sample; range = input max value - min value; delta = step size; l = number of levels;

8 years ago

Solved


Create a New_Word
The output of the function is a new word created from the word entered into the function. The new word is created by deleting th...

8 years ago

Solved


A uniform quantizer
Find the total number of quantization levels and step size for a 3 bit bipolar quantizer for an input analog signal ranges from ...

8 years ago

Load more