解決済み


Draw 'I'
Given n as input, draw a n-by-n matrix 'I' using 0 and 1. example: n=3 ans= [0 1 0 0 1 0 0 1 0] n=...

8年以上 前

解決済み


Draw 'O' !
Given n as input, generate a n-by-n matrix 'O' using 0 and 1 . example: n=4 ans= [1 1 1 1 1 0 0 1 ...

8年以上 前

解決済み


Day counter function
Write a function called _day_counter_ that returns the number of Mondays that fell on the first day of the month in a given year...

8年以上 前

解決済み


Dial Up
Each number on telephone keypads, except 0 and 1, corresponds to a set of uppercase letters as shown in this list: 2 ABC, 3 DEF...

8年以上 前

解決済み


Basic Quadratic Equation
Create the equation: y=(3x)^2+(5x)+35 and compute y for various values of x

8年以上 前

解決済み


Find last non-zero in a given dimension
You are given a logical matrix *BW* _of any dimension_, and a dimension *dim*. You need to find the locations of the last non-ze...

8年以上 前

解決済み


Weave two matrices together to form one matrix
Take the first column from matrix a, then insert the first column from matrix b, and so on. For example: a = [1 2 3 4]; b ...

8年以上 前

解決済み


Check if a rotated array was originally sorted
Suppose a sorted array is rotated at some pivot unknown to you. For example, |[0 1 2 4 5 6 7]| might become |[5 6 7 0 1 2 4]|. ...

8年以上 前

解決済み


Draw a 'N'!
Given n as input, generate a n-by-n matrix 'N' using 0 and 1 . Example: n=5 ans= [1 0 0 0 1 1 1 0 0 1 1 0 ...

8年以上 前

解決済み


Goldbach's marginal conjecture - Write integer as sum of three primes
Goldbach's strong conjecture states that every even integer greater than 2 can be expressed as the sum of two primes. For exampl...

8年以上 前

解決済み


convert the number to binary format & count digits
Convert the given number to the corresponding binary format and count the number of digits in that binary number

8年以上 前

解決済み


P-smooth numbers
This Challenge is to find <https://en.wikipedia.org/wiki/Smooth_number P-smooth number> partial sets given P and a max series va...

8年以上 前

解決済み


Champernowne Constant
The <http://en.wikipedia.org/wiki/Champernowne_constant Champernowne constant> is a real number whose digits in decimal represen...

8年以上 前

解決済み


Try your chance!!!
There is a bomb in 3 cell! You must avoid to select the bomb. choose one of these cells and try your chance: 1 2 3 ?...

8年以上 前

解決済み


Code breaker, Part I: Operation Phoenix
You have been tasked with decoding a set of coded messages that have been intercepted. Based on previous intelligence that ...

8年以上 前

解決済み


Guess the number I'm thinking of
In this game you are competing against two other people to guess the number that I'm thinking of. # I randomly choose an *i...

8年以上 前

解決済み


Still more miles to go before I sleep
It's time for more odometer fun. Last problem, my car's odometer hit 56789. It's coming up on 111111 now, which (barring a maj...

8年以上 前

問題


Still more miles to go before I sleep
It's time for more odometer fun. Last problem, my car's odometer hit 56789. It's coming up on 111111 now, which (barring a maj...

8年以上 前 | 7 | 57 個のソルバー

解決済み


The twelve days of Christmas
Traditionally there are twelve days of Christmas to celebrate ("Twelvetide"), typically starting with Christmas Day (25 December...

8年以上 前

解決済み


The answer to life the universe and everything
Write a function that gives the answer to life the universe and everything to every input except the input is 42. In this case t...

8年以上 前

解決済み


The other half of the Fibonacci sequence
The <http://mathworld.wolfram.com/FibonacciNumber.html "Fibonacci sequence"> — F = [1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144,...

8年以上 前

解決済み


Separate even from odd numbers in a vector - with a loop
*Using a loop*, rearrange a vector of integers such that the odd numbers appear at the beginning, and even numbers at the end. T...

8年以上 前

解決済み


Find the average of a random sequance
Write a function that generates random integers within a loop, and calculates the mean of the positive numbers only. At each ...

8年以上 前

解決済み


How to reverse spdiags ?
The spdiags function extracts all nonzero diagonals from the m-by-n matrix A. So if A=[1 2 3;4 5 6;7 8 9], spdiags(A)=[7 4...

8年以上 前

解決済み


Funny problems
Generate the following vector: if n=1 then q=1; elseif n=2 then q=[2 2 1]; elseif n=3 then q=[3 3 3 2 2 1]; ... end

8年以上 前

解決済み


Pattern Sum
Write a function which receives two single digit positive integers, (k and m) as parameters and calculates the total sum as: k...

8年以上 前

解決済み


Perimeter of a quadrilateral
There are four cars starting at a point. The first car points north, the second one points east, the third one points south, an...

8年以上 前

解決済み


Happy Free March!
Just submit your solution in any March. *Related Challenges:* # <https://www.mathworks.com/matlabcentral/cody/problems/445...

8年以上 前

解決済み


Read it !
read and return the following word. 'M M A TTTTTTTTTL A BBB ' 'MM MM A A T L ...

8年以上 前

解決済み


2) Are you more familiar with iteration methods or Linear Algebra ? Let's see together.
Referring to problem: https://www.mathworks.com/matlabcentral/cody/problems/44530-are-you-more-familiar-with-iteration-method...

8年以上 前

さらに読み込む