Solved


Check p = 4n +/- 1, the generic formula for odd prime numbers
Problem statement For all odd prime number p, there exists a positive integer n, such that p = 4n +/- 1 : Check this f...

11 months ago

Solved


Find Logic 32

11 months ago

Solved


Find Logic 31

11 months ago

Solved


Find Logic 14
Guess the Logic! logic(1) = 100 logic(2) = 96 logic(3) = 105 logic(4) = 89 logic(5) = 114 Make a function logic(x) which w...

11 months ago

Solved


Find Logic 11

11 months ago

Solved


Find Logic 10

11 months ago

Solved


Find Logic 9
Guess the Logic! logic(1) = 4 logic(2) = 1 logic(3) = 10 logic(4) = 2

11 months ago

Solved


Find Logic 7

11 months ago

Solved


Find Logic 6

11 months ago

Solved


Find Logic 3

11 months ago

Solved


Find Logic 1

11 months ago

Solved


Mass Conversion 2

11 months ago

Solved


sum of non-primes
The sum of the non-primes no larger than 10 is 1+4+6+8+9+10=38 Find the sum of all the positive non-prime integers that do no...

11 months ago

Solved


subtract central cross
Given an n-by-n square matrix, where n is an odd number, return the matrix without the central row and the central column.

11 months ago

Solved


Given a number N, find the smallest prime P>N
Given a number N, find the smallest prime P greater than N. For example: If N=10 then P=11. If N=13 then P=17.

11 months ago

Solved


Pi Digit Probability
Assume that the next digit of pi constant is determined by the historical digit distribution. What is the probability of next di...

11 months ago

Solved


Approximation of Pi
Pi (divided by 4) can be approximated by the following infinite series: pi/4 = 1 - 1/3 + 1/5 - 1/7 + ... For a given number of...

11 months ago

Solved


Create an arrow matrix
An arrow matrix is a square matrix that contains ones on the diagonal, the last column, and last row. ...

11 months ago

Solved


Calculating Student Grades
The matrix grades contains raw grades for 7 students who took your course. Each row represents a different student. The first 7 ...

11 months ago

Solved


Determine if x is a combination of m and n
Given positive integers x, m, and n, determine if x can be written as x = am + bn for any (non-negative) integers a and b. Your ...

11 months ago

Solved


Generate this matrix
Generate the following matrix. n = 2; out = [-4 -3 -2 -1 0 -3 -2 -1 0 1 -...

11 months ago

Solved


Simpson's Paradox - Calculate correlation coefficients for groups of data
Simpson's Paradox is a statistical phenomenon where groups of data can have a characteristic while the whole data set together h...

11 months ago

Solved


Find the minimum of the column-maximums of a matrix
Given a matrix A, find the maximum value of each column, then return the smallest of those maximum values (ie return the minimum...

11 months ago

Solved


Calculate the mean of each half of a matrix
Given a matrix with an even number of columns, n, return a 1-by-2 row vector where the first element is the mean of all the elem...

11 months ago

Solved


Find Closest Constant
Given a number x, return the value that is closest to x from this list of constants: 0, 1, , e, , (also known as ). For exampl...

11 months ago

Solved


Matrix Quadrants
Write a function that takes N as the input, and outputs a matrix whose upper-left (NxN) quadrant contains all ones, the lower-ri...

11 months ago

Solved


Convert a Cell Array into an Array
Given a square cell array: x = {'01', '56'; '234', '789'}; return a single character array: y = '0123456789'

11 months ago

Solved


Split a string into chunks of specified length
Given a string and a vector of integers, break the string into chunks whose lengths are given by the elements of the vector. Ex...

11 months ago

Solved


String Array Basics, Part 1: Convert Cell Array to String Array; No Missing Values
<http://www.mathworks.com/help/matlab/characters-and-strings.html String array> and cell array are two types of containers for s...

11 months ago

Solved


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

11 months ago

Load more