Community Profile

# Dean

### Ford Motor Co

85 total contributions since 2019

View details...

Contributions in
View by

Solved

Find the longest sequence of 1's in a binary sequence.
Given a string such as s = '011110010000000100010111' find the length of the longest string of consecutive 1's. In this examp...

etwa ein Jahr ago

Solved

Tick. Tock. Tick. Tock. Tick. Tock. Tick. Tock. Tick. Tock.
Submit your answer to this problem a multiple of 5 seconds after the hour. Your answer is irrelevant; the only thing that matte...

etwa ein Jahr ago

Solved

Area of an equilateral triangle
Calculate the area of an equilateral triangle of side x. <<http://upload.wikimedia.org/wikipedia/commons/e/e0/Equilateral-tr...

etwa ein Jahr ago

Solved

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

etwa ein Jahr ago

Solved

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

etwa ein Jahr ago

Solved

Summing digits
Given n, find the sum of the digits that make up 2^n. Example: Input n = 7 Output b = 11 since 2^7 = 128, and 1 + ...

etwa ein Jahr ago

Solved

Swap two numbers
Example Input: a = 10 b = 20 Output a = 20 b = 10

etwa ein Jahr ago

Solved

"mirror" matrix
Create n x 2n "mirror" matrix of this type: Examples For n = 2 m = [ 1 2 2 1 1 2 2 1 ] For n = 3 m = ...

etwa ein Jahr ago

Solved

Basic arrays operations.
Apply element-by-element binary operation 'fun' to two arrays (A and B).

etwa ein Jahr ago

Solved

Flipping
Write code that can reverse the vector without using any sort of loop. Example Given the input vector A = [ 1 2 3 4 5...

etwa ein Jahr ago

Solved

You just measured its surface area, that is the input.

etwa ein Jahr ago

Solved

Return 'on' or 'off'
When the input is true, return 'on', otherwise, return 'off'.

etwa ein Jahr ago

Solved

Is this triangle right-angled?
Given three positive numbers a, b, c, where c is the largest number, return *true* if the triangle with sides a, b and c is righ...

etwa ein Jahr ago

Solved

Is the input divisible by 3?
Return true if the input is divisible by 3 and false if not.

etwa ein Jahr ago

Solved

Fahrenheit to Celsius converter
Convert Fahrenheit to Celsius degrees.

etwa ein Jahr ago

Solved

Back and Forth Rows
Given a number n, create an n-by-n matrix in which the integers from 1 to n^2 wind back and forth along the rows as shown in the...

etwa ein Jahr ago

Solved

Generate a NaN...on purpose
The goal is to create a function that will return a single "NaN" without using the nan function. I am interested to see how many...

etwa ein Jahr ago

Solved

Getting the row and column location from a matrix
This is a basic MATLAB operation. It is for instructional purposes. --- You may already know how to get <http://www.mathwo...

etwa ein Jahr ago

Solved

Create a two dimensional zero matrix
You have to create a zero matrix of size (mxn) whose inputs are m and n and the elements of your matrix should be zeros. Exam...

etwa ein Jahr ago

Solved

Return the 3n+1 sequence for n
A Collatz sequence is the sequence where, for a given number n, the next number in the sequence is either n/2 if the number is e...

etwa ein Jahr ago

Solved

The Hitchhiker's Guide to MATLAB
Output logical "true" if the input is the answer to life, the universe and everything. Otherwise, output logical "false".

etwa ein Jahr ago

Solved

Pascal's Triangle
Given an integer n >= 0, generate the length n+1 row vector representing the n-th row of <http://en.wikipedia.org/wiki/Pascals_t...

etwa ein Jahr ago

Solved

Matlab Basics - Convert a row vector to a column vector
Write a script to convert a row (e.g. x = [1 2 3]) to a column (e.g. y = [1;2;3]), your script should be able to do this for any...

etwa ein Jahr ago

Solved

Area of a disk
Find the area of a disk or circle. x= radius of the disk.

etwa ein Jahr ago

Solved

Matlab Basics - Set unwanted parts of a vector to zero
Consider a vector x, of length >= 7, write a script to set elements 2, 5, and 6 to zero. Example x = [1 2 3 4 5 6 7] --> ...

etwa ein Jahr ago

Solved

Remove the vowels
Remove all the vowels in the given phrase. Example: Input s1 = 'Jack and Jill went up the hill' Output s2 is 'Jck nd Jll wn...

etwa ein Jahr ago

Solved

Back to basics - mean of corner elements of a matrix
Calculate the mean of corner elements of a matrix. e.g. a=[1 2 3; 4 5 6; 7 8 9;] Mean = (1+3+7+9)/4 = 5

etwa ein Jahr ago

Solved

What percentage?
Calculate the output c as the percentage of a on b for given a and b.

etwa ein Jahr ago

Solved

Reverse the elements of an array
Reverse the order of elements in an array: eg: input X = [ 1 2 3 ; 4 5 6 ; 7 8 9 ] o...

etwa ein Jahr ago

Solved

Box!
Given a box, find the volume of the cube. With each side = a.

etwa ein Jahr ago