Risolto


cross in array
Make a cross from "1" in odd size array. Other value from array should be equal to "0"; As input you get length of side of arra...

oltre un anno fa

Risolto


angle in regular polygon
Make a function which returns measure of interior angle in x-side regular polygon. x is as input. Please pay attention, that 1 ...

oltre un anno fa

Risolto


Basic commands - rounding
make a function which will round to integer, which is nearer to zero. Example x=[-2.5 2]; y=[-2 2];

oltre un anno fa

Risolto


Sudoku square
We have a small Sudoku square, but one number is missing. x = [ 1 5 4 8 6 3 0 9 7 ] Make a function, wher...

oltre un anno fa

Risolto


Interior angles
Find the sum of interior angles for polygon of x sides.

oltre un anno fa

Risolto


prime test 2
enter the only non prime,non composite number

oltre un anno fa

Risolto


Average Grade
Given a 1x5 vector presents the grades of a student on five tests. Calculate the average grade of that student.

oltre un anno fa

Risolto


Create a square matrix of zeros of even order
Create a square matrix of zeros of even order

oltre un anno fa

Risolto


calculate the tangent of angle in radians
Calculate the tangent of angle in degrees

oltre un anno fa

Risolto


Travel time
Calculate the time (in hours) it takes a car traveling at a given uniform speed of s km/hour to travel a distance of d km. For i...

oltre un anno fa

Risolto


Function substitution (2)
Evaluate the function for the given values of the variables N and t

oltre un anno fa

Risolto


Function substitution (1)
Evaluate the function for the given values of the variables N and t

oltre un anno fa

Risolto


Array Concatenation (2)
Given two matrices, a and b, concatenate the two matrices vertically, i.e., the number of rows of the result should be equal to ...

oltre un anno fa

Risolto


Mathematical formula
Find the value of the expression given the values of variables t and k. Assume g=9.81

oltre un anno fa

Risolto


Array Concatenation (1)
Given two matrices, a and b, concatenate the two matrices horizontally, i.e., the number of columns of the result should be equa...

oltre un anno fa

Risolto


High school cafeteria
Given an input vector of positive integers, return a row vector with the primes first (in increasing order) and the composites n...

oltre un anno fa

Risolto


Volume of a sphere given its surface area
You just measured its surface area, that is the input.

oltre un anno fa

Risolto


Palindrome Checker
Check to see if a given string is a palindrome (a word, phrase, or sequence that reads the same backward as forward). Output sh...

oltre un anno fa

Risolto


Convert RGB to Grayscale
Convert a 3 element RGB array to its correspoding grayscale pixel (a scalar) *Hint: a formula exists!

oltre un anno fa

Risolto


Return the Fibonacci Sequence
Write a code which returns the Fibonacci Sequence such that the largest value in the sequence is less than the input integer N. ...

oltre un anno fa

Risolto


Specific Element Count
Given a vector _v_ and a element _e_, return the number of occurrences of _e_ in _v_. Note: NaNs are equal and there may be n...

oltre un anno fa

Risolto


Relative ratio of "1" in binary number
Input(n) is positive integer number Output(r) is (number of "1" in binary input) / (number of bits). Example: * n=0; r=...

oltre un anno fa

Risolto


Converting binary to decimals
Convert binary to decimals. Example: 010111 = 23. 110000 = 48.

oltre un anno fa

Risolto


Mersenne Primes
A Mersenne prime is a prime number of the form M = 2^p - 1, where p is another prime number. For example, 31 is a Mersenne prim...

oltre un anno fa

Risolto


Sophie Germain prime
In number theory, a prime number p is a *Sophie Germain prime* if 2p + 1 is also prime. For example, 23 is a Sophie Germain prim...

oltre un anno fa

Risolto


Back to basics 14 - Keywords
Covering some basic topics I haven't seen elsewhere on Cody. Return a cell array of all MATLAB keywords

oltre un anno fa

Risolto


Get the elements of diagonal and antidiagonal for any m-by-n matrix
In the problem <http://www.mathworks.com/matlabcentral/cody/problems/858-permute-diagonal-and-antidiagonal Problem 858. Permute ...

oltre un anno fa

Risolto


Return unique values without sorting
If the input vector A is [42 1 1], the output value B must be the unique values [42 1] The values of B are in the same order a...

oltre un anno fa

Risolto


Project Euler: Problem 5, Smallest multiple
2520 is the smallest number that can be divided by each of the numbers from 1 to 10 without any remainder. What is the smalle...

oltre un anno fa

Risolto


Project Euler: Problem 7, Nth prime
By listing the first six prime numbers: 2, 3, 5, 7, 11, and 13, we can see that the 6th prime is 13. What is the Nth prime numb...

oltre un anno fa

Carica altro