A résolu


Area of a circle
Find the area of a circle. let x be the radius

plus de 7 ans il y a

A résolu


Rounding
Round a number

plus de 7 ans il y a

A résolu


find the area of rectangle
find the area of the rectangle given the length and width

plus de 7 ans il y a

A résolu


MPH to MPS
Given mps, find the speed in miles per hour.

plus de 7 ans il y a

A résolu


Kinetic Energy
Given mass, m, and kinetic energy, KE, find the velocity of the object.

plus de 7 ans il y a

A résolu


Roll the Dice!
*Description* Return two random integers between 1 and 6, inclusive, to simulate rolling 2 dice. *Example* [x1,x2] =...

plus de 7 ans il y a

A résolu


Bottles of beer
Given an input number representing the number of bottles of beer on the wall, output how many are left if you take one down and ...

plus de 7 ans il y a

A résolu


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

plus de 7 ans il y a

A résolu


Swap the input arguments
Write a two-input, two-output function that swaps its two input arguments. For example: [q,r] = swap(5,10) returns q = ...

plus de 7 ans il y a

A résolu


radius of a spherical planet
you just measured its surface area, that is the input.

plus de 7 ans il y a

A résolu


Create a row array using double colon operator
Create a row array from 9 to 1, using the double colon operator.

plus de 7 ans il y a

A résolu


Simple equation: Annual salary
Given an hourly wage, compute an annual salary by multiplying the wage times 40 and times 50, because salary = wage x 40 hours/w...

plus de 7 ans il y a

A résolu


Circle area using pi
Given a circle's radius, compute the circle's area. Use the built-in mathematical constant pi.

plus de 7 ans il y a

A résolu


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

plus de 7 ans il y a

A résolu


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

plus de 7 ans il y a

A résolu


Times 2 - START HERE
Try out this test problem first. Given the variable x as your input, multiply it by two and put the result in y. Examples:...

plus de 7 ans il y a

A résolu


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

plus de 7 ans il y a

A résolu


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

plus de 7 ans il y a

A résolu


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

plus de 7 ans il y a