Solved

Mysterious digits operation (easy)
What is this digit operation? 0 -> 0 1 -> 9 121 -> 9 44 -> 6 15 -> 5 1243 -> 7 ...

4 years ago

Problem

Delete the column with all 0 in the TABLE
In the given table (T), delete the column with all 0 data. e.g. input Banana Apple Orange Mellon __...

4 years ago | 1 | 21 solvers

Problem

Delete the column with all 0 !
Delete the column with all 0 data in a matrix(x). e.g. input x = 1 0 0 4 5 0 7 0 ...

4 years ago | 0 | 44 solvers

Solved

Reverse a string
Reverse the given string. Example input = 'reverse' output = 'esrever'

4 years ago

Solved

UICBioE240 problem 1.1
Remove the middle row from a matrix, assuming # of rows is odd. So if A = [ 1 2 3; 4 5 6; 7 8 9] the...

4 years ago

Solved

Change matrix to vector
Vector is a matrix whose size is 1 x n or n x 1. Change matrix to vector. x = 4 3 5 1 ...

4 years ago

Solved

Rounding off numbers to n decimals
Inspired by a mistake in one of the problems I created, I created this problem where you have to round off a floating point numb...

4 years ago

Solved

Sum the 'edge' values of a matrix
Sum the 'edge' values of an input matrix (the values along the perimeter). Example [1 2 3 4 5 6 7 8 9] Output = ...

4 years ago

Solved

Magic is simple (for beginners)
Determine for a magic square of order n, the magic sum m. For example m=15 for a magic square of order 3.

4 years ago

Solved

Calculate area of sector
A=function(r,seta) r is radius of sector, seta is angle of sector, and A is its area. Area of sector A is defined as 0.5*(r^2...

4 years ago

Solved

Replace values under a limit
For a vector x and number n, the goal is to find every element of x inferior to n and replace it by n. Example x= [ 1 2 3...

4 years ago

Solved

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

4 years ago

Solved

Where is the number that you want to find?
For a given matrix A, find where the input number x appears. Do this task by returning the vector which contains the row and th...

4 years ago

Solved

Tent matrix
Create an n x n matrix that resembles one kind of tent. The variable n is provided to the function and will be an odd number. As...

4 years ago

Solved

UICBioE240 problem 1.6
Find the tangent line of a right triangle given the two of the sides. So if A = [1 1] B = sqrt(2)

4 years ago

Solved

Which coins to give
I was in shop today. I admired, how shop assistant had to think, which coins to give me. The task is we have a vector v=[0.5 0....

4 years ago

Problem

Replace Nan!
Replace Nan in the given vector(v) with 9999.

4 years ago | 2 | 62 solvers

Solved

Area of a Square
Given the length x of the side of a regular square, find the area of the square, A.

4 years ago

Solved

Return a list sorted by number of consecutive occurrences
Inspired by Problem 38 by Cody Team. Given a vector x, return a vector y of the values in x sorted by the number of CONSECUTIVE...

4 years ago

Solved

"Low : High - Low : High - Turn around " -- Create a subindices vector
Let two vectors *lo* and *hi* be given. The job is to create a index vector like so idx = [lo(1):hi(1) lo(2):hi(2) ...]...

4 years ago

Solved

Duplicates
Write a function that accepts a cell array of strings and returns another cell array of strings *with only the duplicates* retai...

4 years ago

Solved

Remove Missing Values from a Table or an Array
Remove missing entries from an array or table. If A is a vector, then remove any entry that contains missing data. If A is a mat...

4 years ago

Solved

Longest run of consecutive numbers
Given a vector a, find the number(s) that is/are repeated consecutively most often. For example, if you have a = [1 2 2 2 1 ...

4 years ago

Solved

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

4 years ago

Solved

Another colon problem
This is simple problem based on problems 555, 801, 1118, etc. Create an index vector from two input vectors. Example: ...

4 years ago

Solved

Replace Negative(-) by 0 and positive by 1
In a given Matrix Replace all element having *Negative sign with 0* and *Positive elements with 1* .

4 years ago

Solved

Shift elements of vector left
Shift elements of vector to the left. For ex. : Input_vec = [1 2 3 4 5] Output_vec = [2 3 4 5 1]

4 years ago

Solved

counting groups!
This problem is about counting groups. Example If you have x: x = [0.8 0.8 0.8 0.3 0.3 0.4 0.5 0.6 0.6 0.9] then a...

4 years ago

Solved

How unique?
Sometimes, when we check unique entries of vector we would like to know how many times each value occurs. Given vector of num...

4 years ago

Solved

Check if a string starts with another string
Input s='He was so tired' q='He' Output ans = true

4 years ago