Community Profile

photo

Owen Mok


Last seen: 3年弱 前 2021 年からアクティブ

Followers: 0   Following: 0

統計

  • Community Group Solver
  • CUP Challenge Master
  • Solver

バッジを表示

Feeds

表示方法

解決済み


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...

3年弱 前

解決済み


Square root of a number
Write a code that will output the square root of x.

3年弱 前

解決済み


Who invented zero?
We know the importance zero in computer science, mathematics... but who invented zero? Clue: He was the first in the line ...

3年弱 前

解決済み


Is A the inverse of B?
Given a matrix A and a matrix B, is A the inverse of B? >>A=[2,4;3,5]; >>B=[-2.5,2;1.5,-1]; >>isInverse...

3年弱 前

解決済み


Create an index-powered vector
Given a input vector x, return y as index-powered vector as shown below. Example x = [2 3 6 9] then y should be [...

3年弱 前

解決済み


Sum of series IV
What is the sum of the following sequence: Σ(-1)^(k+1) (2k-1)^2 for k=1...n for different n?

3年弱 前

解決済み


Sum of series I
What is the sum of the following sequence: Σ(2k-1) for k=1...n for different n?

3年弱 前

解決済み


Determine the mean of matrix
Determine the mean of matrix without using mean function Hint: use simple algorithm

3年弱 前

解決済み


Remove the Zero
Given an array n, remove all zeros

3年弱 前

解決済み


Add two numbers
Given a and b, return the sum a+b in c.

3年弱 前

解決済み


Make the vector [1 2 3 4 5 6 7 8 9 10]
In MATLAB, you create a vector by enclosing the elements in square brackets like so: x = [1 2 3 4] Commas are optional, s...

3年弱 前

解決済み


Make a checkerboard matrix
Given an integer n, make an n-by-n matrix made up of alternating ones and zeros as shown below. The a(1,1) should be 1. Examp...

3年弱 前

解決済み


Vector creation
Create a vector using square brackets going from 1 to the given value x in steps on 1. Hint: use increment.

3年弱 前

解決済み


Doubling elements in a vector
Given the vector A, return B in which all numbers in A are doubling. So for: A = [ 1 5 8 ] then B = [ 1 1 5 ...

3年弱 前

解決済み


Create a vector
Create a vector from 0 to n by intervals of 2.

3年弱 前

解決済み


Flip the vector from right to left
Flip the vector from right to left. Examples x=[1:5], then y=[5 4 3 2 1] x=[1 4 6], then y=[6 4 1]; Request not ...

3年弱 前

解決済み


Whether the input is vector?
Given the input x, return 1 if x is vector or else 0.

3年弱 前

解決済み


Find max
Find the maximum value of a given vector or matrix.

3年弱 前

解決済み


Get the length of a given vector
Given a vector x, the output y should equal the length of x.

3年弱 前

解決済み


Inner product of two vectors
Find the inner product of two vectors.

3年弱 前

解決済み


Arrange Vector in descending order
If x=[0,3,4,2,1] then y=[4,3,2,1,0]

3年弱 前

解決済み


Select every other element of a vector
Write a function which returns every other element of the vector passed in. That is, it returns the all odd-numbered elements, s...

3年弱 前

解決済み


Find the sum of all the numbers of the input vector
Find the sum of all the numbers of the input vector x. Examples: Input x = [1 2 3 5] Output y is 11 Input x ...

3年弱 前

解決済み


Find out Harmonic mean.
Find out Harmonic mean.

3年弱 前

解決済み


Find out magnitude of vector
Find out magnitude of vector. Say x=[1 2 3], then answer must sqrt(1^2+2^2+3^2) Please don't use sum function. If you l...

3年弱 前

解決済み


If you have matrix A, create matrix B using matrix A as an "element"
A = [1 2 3 4; 5 6 7 8] B = [1 2 3 4 1 2 3 4; 5 6 ...

3年弱 前

解決済み


Find the minimum element of the matrix
Example: If x = [3 9; 5 2] then y = 2

3年弱 前

解決済み


Switch matrix to a column vector
for e.g. x = [1 2 3 4] y = 1 3 2 4

3年弱 前

解決済み


Sum all integers from 1 to 2^n
Given the number x, y must be the summation of all integers from 1 to 2^x. For instance if x=2 then y must be 1+2+3+4=10.

3年弱 前

解決済み


Dimensions of a rectangle
The longer side of a rectangle is three times the length of the shorter side. If the length of the diagonal is x, find the width...

3年弱 前

さらに読み込む