Gelöst


Complex number
For complex number c=a+bi, write code that will add a and b together.

mehr als 5 Jahre vor

Gelöst


Back to basics 8 - Matrix Diagonals
Covering some basic topics I haven't seen elsewhere on Cody. Given an input vector of numbers, output a square array with the...

mehr als 5 Jahre vor

Gelöst


Remove the Zero
Given an array n, remove all zeros

mehr als 5 Jahre vor

Gelöst


Area of a circle
Find the value for area of the circle if diameter is given

mehr als 5 Jahre vor

Gelöst


Sorted highest to lowest?
Return 1 if the input is sorted from highest to lowest, 0 if not. Example: 1:7 -> 0 [7 5 2] -> 1

mehr als 5 Jahre vor

Gelöst


Perimeter of a semicircle
Given the diameter d, find the perimeter of a semicircle

mehr als 5 Jahre vor

Gelöst


Area of an equilateral triangle
Calculate the area of an equilateral triangle of side x. <<https://i.imgur.com/jlZDHhq.png>> Image courtesy of <http://up...

mehr als 5 Jahre vor

Gelöst


Find all elements less than 0 or greater than 10 and replace them with NaN
Given an input vector x, find all elements of x less than 0 or greater than 10 and replace them with NaN. Example: Input ...

mehr als 5 Jahre vor

Gelöst


Piecewise linear interpolation
Given an Mx2 vector and a row of M-1 integers, output a two column vector that linearly interpolates Y times between each succes...

mehr als 5 Jahre vor

Gelöst


Pattern Sum
Write a function which receives two single digit positive integers, (k and m) as parameters and calculates the total sum as: k...

mehr als 5 Jahre vor

Gelöst


Find the Best Hotels
Given three input variables: * |hotels| - a list of hotel names * |ratings| - their ratings in a city * |cutoff| - the rat...

mehr als 5 Jahre vor

Gelöst


Solve the Sudoku Row
*Description* A simple yet tedious task occurs near the end of most Sudoku-solving algorithms, computerized or manual. The ta...

mehr als 5 Jahre vor

Gesendet


patterned_movie
a small animated movie of creating a graphic shown in image.

mehr als 5 Jahre vor | 1 Download |

5.0 / 5
Thumbnail

Gelöst


Plot Damped Sinusoid
Given two vectors |t| and |y|, make a plot containing a blue ( |b| ) dashed ( |--| ) line of |y| versus |t|. Mark the minimum...

mehr als 5 Jahre 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...

mehr als 5 Jahre vor

Gelöst


Matrix for beginners
Multiply x and y elemwise.

fast 6 Jahre vor

Gelöst


Momentum of an Object
P is momentum, m is mass, and v is velocity. Calculate the momentum for an object.

fast 6 Jahre vor

Gelöst


Newton's Motion Law
F is force, m is mass, and a is acceleration. Calculate the force for an object.

fast 6 Jahre vor

Gelöst


Speed
x is distance, v is speed, and t is time. Calculate the speed for an object.

fast 6 Jahre vor

Gelöst


Equilateral Triangle
The length of one side of the equilateral triangle is a. Calculate the area of ​​the equilateral triangle.

fast 6 Jahre vor

Gelöst


Right and wrong
Given a vector of lengths [a b c], determines whether a triangle with those sides lengths is a right triangle: <http://en.wikipe...

fast 6 Jahre vor

Gelöst


Is my wife right?
Regardless of input, output the string 'yes'.

fast 6 Jahre vor

Gelöst


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

fast 6 Jahre vor

Gelöst


Determine if input is odd
Given the input n, return true if n is odd or false if n is even.

fast 6 Jahre vor

Gelöst


Determine Whether an array is empty
Input a matrix x, output y is TRUE if x is empty, otherwise FALSE.

fast 6 Jahre vor

Gelöst


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

fast 6 Jahre vor

Gelöst


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

fast 6 Jahre vor

Gelöst


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

fast 6 Jahre vor

Gelöst


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

fast 6 Jahre vor

Gelöst


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

fast 6 Jahre vor

Mehr laden