A résolu


Extract leading non-zero digit (★★★★★)
(Copy of Problem 47) Benford's Law states that the distribution of leading digits is not random. This is probably because man...

plus de 5 ans il y a

A résolu


Remove the row average (★★★)
(copy of Prob. 963) Given a 2-d matrix, remove the row average from each row. Your solution MUST be vectorized. The solut...

plus de 5 ans il y a

A résolu


Matrix Pattern 7

plus de 5 ans il y a

A résolu


Matrix Pattern 9

plus de 5 ans il y a

A résolu


Matrix Pattern 5

plus de 5 ans il y a

A résolu


Matrix Pattern 2

plus de 5 ans il y a

A résolu


Matrix Pattern 1

plus de 5 ans il y a

A résolu


provide the numerical answer to these number questions...
return a row matrix containing the sorted numbers which answer the following questions: a) what is the first Knuth number to...

plus de 5 ans il y a

A résolu


The Matrix Construction
Given two input ,first one is CN (Column Number), Second one is Dim Can you produce such a matrix for example CN=6; Dim=2 ...

plus de 5 ans il y a

A résolu


Create a block diagonal matrix
A block diagonal matrix is a square matrix that can be written as A = [a 0 0 0 0 b 0 0 0 0 c 0 ...

plus de 5 ans il y a

A résolu


Pascal's pyramid
In Pascal's triangle each number is the sum of the two nearest numbers in the line above: 1 1 1 ...

plus de 5 ans il y a

A résolu


Throwing Dice - Will You Be Eaten By The Dragon?
You and a dragon have agreed to let dice rolls determine whether it eats you or not. The dragon will roll a single die, of x ...

plus de 5 ans il y a

A résolu


Is this date a palindrome?emordnilap a etad siht sI
Take a MATLAB date number as input, and return true if the date is a palindrome, false if the date is not a palindrome. A date ...

plus de 5 ans il y a

A résolu


How Many Months Until It's Today Again?
Given a particular date, calculate how many months must pass before that same day of the month occurs on the same day of the wee...

plus de 5 ans il y a

A résolu


weekday and month
Given a year and a weekday, determine how many months of that year had five of those weekdays. It is kind of easy to find. Ex...

plus de 5 ans il y a

A résolu


Get an array of month-ends in a date range
Create a function that would return a list of month-ends falling in a given date range. If a start date or end date falls on a...

plus de 5 ans il y a

A résolu


Lost days
Given two dates in a particular format, calculate the difference between them.

plus de 5 ans il y a

A résolu


Calendar Matrix
Return a calendar matrix for the given values of month and year. Assume that Sunday is the first day of the week. The resulting ...

plus de 5 ans il y a

A résolu


Friday the 13th
According to superstition, lots of unpleasant stuff happens on Friday the 13th, so you might like to find the next occurence of ...

plus de 5 ans il y a

A résolu


Count the days
Count the occurrence of a particular day (e.g. Monday) in a given year.

plus de 5 ans il y a

A résolu


How long until the weekend?
Write a function a that takes a date vector as an input and returns the number of hours until the weekend begins. The beginning...

plus de 5 ans il y a

A résolu


Days until next NewYear ball drop
Given a date string in the form 'yyyy-mm-dd' or 'yyyy-mm-dd hh:mm:ss', calculate the number of *days* until the dropping of the ...

plus de 5 ans il y a

A résolu


Tax Season ! How much is my salary?
Tax Season! I was employed for a period from x until y in a year and I get pay check of amount z on every alternate Friday of th...

plus de 5 ans il y a

A résolu


Find supported functions
Given a function name, return true if that function is supported by the toolboxes that are installed with MATLAB on this machine...

plus de 5 ans il y a

A résolu


Join Strings with Multiple Different Delimiters
The idea is to form the string S by interleaving the elements of a cell array of strings DELIMITER and another cell array of st...

plus de 5 ans il y a

A résolu


Eliminate Polysyllabics: Long live short words!
Given a string s1, return s2 in which all the words with more than one syllable have been removed. To make things simple, we ...

plus de 5 ans il y a

A résolu


Elapsed time is -0.005204 seconds.
Write a function that takes less than zero seconds to execute, as measured using tic and toc. For repeatability, the test case p...

plus de 5 ans il y a

A résolu


Generate a melodic contour string matrix
<http://en.wikipedia.org/wiki/Parsons_code Parsons code> is a surprisingly effective way to identify music by its melodic motion...

plus de 5 ans il y a

A résolu


Is the paranthesis sequence balanced ?
Quantum mechanics and computer science are interested in <http://en.wikipedia.org/wiki/Bra%E2%80%93ket_notation bra-kets>. Today...

plus de 5 ans il y a

Charger plus