Gelöst


Pizza!
Given a circular pizza with radius z and thickness a, return the pizza's volume. [ z is first input argument.] Non-scored bonus...

3 Monate vor

Gelöst


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

3 Monate vor

Gelöst


Find sum of alternate numbers in a vector
Find sum of alternate numbers in a vector starting from index 1

mehr als ein Jahr vor

Gelöst


Set x value to each even index of vector y.
Set x value to each even index of vector y.

mehr als ein Jahr vor

Gelöst


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

mehr als ein Jahr vor

Gelöst


Finding an element in a vector
x is a vector of unknown length your function should return the index of the first element in the vector that is greater than...

mehr als ein Jahr vor

Gelöst


Vector indexing: lower than mean
Find indices of values in a vector lower than the mean of the vector

mehr als ein Jahr vor

Gelöst


Set x value to each odd index of vector y.
Set x value to each odd index of vector y.

mehr als ein Jahr vor

Gelöst


find the index of a number

mehr als ein Jahr vor

Gelöst


Getting values from a vector
This exercise is for finding the values that meet your criteria. a = [-5 28 7 83 73]; b = 23 ; c = (a > b) Then : c = ...

mehr als ein Jahr vor

Gelöst


Increment a number, given its digits
Take as input an array of digits (e.g. x = [1 2 3]) and output an array of digits that is that number "incremented" properly, (i...

mehr als ein Jahr vor

Gelöst


Convert a numerical matrix into a cell array of strings
Given a numerical matrix, output a *cell array of string*. For example: if input = 1:3 output is {'1','2','3'} whic...

mehr als ein Jahr vor

Gelöst


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

mehr als ein Jahr vor

Gelöst


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

mehr als ein Jahr vor

Gelöst


Determine if a row vector has NaN
Determine if a row vector x has NaN

mehr als ein Jahr vor

Gelöst


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

mehr als ein Jahr vor

Gelöst


Speed of car
Calculate the Speed of car given its Distance travelled and time taken in x and y respectively

mehr als ein Jahr vor

Gelöst


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

mehr als ein Jahr vor

Gelöst


Find the biggest empty box
You are given a matrix that contains only ones and zeros. Think of the ones as columns in an otherwise empty floor plan. You wan...

fast 2 Jahre vor

Gelöst


How many trades represent all the profit?
Given a list of results from trades made: [1 3 -4 2 -1 2 3] We can add them up to see this series of trades made a profit ...

fast 2 Jahre vor

Gelöst


Given a window, how many subsets of a vector sum positive
Given a vector: [1 0 -1 3 2 -3 1] and a window of 2, A sliding window would find: 1 + 0 = 1 0 - 1 = -1 ...

fast 2 Jahre vor

Gelöst


Make a run-length companion vector
Given a vector x, return a vector r that indicates the run length of any value in x. Each element in r shows how many times the ...

fast 2 Jahre vor

Gelöst


Flag largest magnitude swings as they occur
You have a phenomenon that produces strictly positive or negative results. delta = [1 -3 4 2 -1 6 -2 -7]; Marching through thi...

fast 2 Jahre vor

Gelöst


Implement simple rotation cypher
If given a letter from the set: [abc...xyz] and a shift, implement a shift cypher. Example: 'abc' with a shi...

fast 2 Jahre vor

Gelöst


Sort Reversal
There are n index cards in a row, with n distinct integers written on them (one number per card) so that the numbers are sorted ...

fast 2 Jahre vor

Gelöst


Implement a bubble sort technique and output the number of swaps required
A bubble sort technique compares adjacent items and swaps them if they are in the wrong order. This is done recursively until al...

fast 2 Jahre vor

Gelöst


Bubble sort
Write your own bubble sort function ( <https://en.wikipedia.org/wiki/Bubble_sort>) to sort all elements in x in ascending order....

fast 2 Jahre vor

Gelöst


Basic Mathematics 1
If a robot is traveling on a north heading at v1 inches per second and has the ability to only make N degree changes in directio...

fast 2 Jahre vor

Gelöst


Basic Mathematics 8
A robot is extending its arm and attempting to reach a game piece that is X” away and Yg ” off the ground. The base of the arm i...

fast 2 Jahre vor

Gelöst


Current through resistor
Three resistors (R2, R3, R4) are connected in parallel as shown in the figure. If this combination is connected in series with ...

fast 2 Jahre vor

Mehr laden