Solved


Constructing strings
* Construct a string alphaString from 'a' to endLetter, using the double colon operator.

9 years ago

Solved


Concatenating strings
* Write a statement that assigns fullName with firstName, a space, then lastName. Ex: If firstName is Alan and lastName is Tu...

9 years ago

Solved


Beginner's Problem - Squaring
Try out this test problem first. Given the variable x as your input, square it by two and put the result in y. Examples: ...

9 years ago

Solved


Find Sign(Zero Crossing) Changes in Array
Example; A = [1 2 3 -3 -4 -1 -24 2 4 -1 -2 3 1]; ans; [1 2 0 -3 -4 -1 0 2 0 -1 ...

9 years ago

Solved


Coordinate geometry
Assign pointsDistance with the distance between point (x1, y1) and point (x2, y2). The distance is calculated by: Distance =...

9 years ago

Solved


Population growth
Assign finalPopulation with the population size given an initial population, population growth rate, and number of years. The po...

9 years ago

Solved


Rule of mixtures (composites) - lower bound
The <http://en.wikipedia.org/wiki/Rule_of_mixtures rule of mixtures> is used in the mechanical design of composite structures to...

9 years ago

Solved


Rule of mixtures (composites) - upper bound
The <http://en.wikipedia.org/wiki/Rule_of_mixtures rule of mixtures> is used in the mechanical design of composite structures to...

9 years ago

Solved


Guess
A random number between 1 and 10 is created for the variable y. Guess what its value is.

9 years ago

Solved


Y=X
Given an input variable x, output a variable y that is equal in value to x. Example: Input x = 1 Output y is 1 Inp...

9 years ago

Solved


Add 7
Given an input variable x, output a variable y that is 7 greater than x. Example: Input x = 1 Output y is 8 Input ...

9 years ago

Solved


Relational operators: Guessing game
* Row array userGuess contains a sequence of user guesses. Assign correctGuess with true when myNumber is equal to the user gues...

9 years ago

Solved


Add 3
Given the variable x as an input, add three to the value, and put the result in y. Example: Input x = 2 Output y is 5...

9 years ago

Solved


Indexing the array: Moving values
* Write three statements to shift the array contents 1 position to the left. * The rightmost element should be assigned -1.

9 years ago

Solved


Linear-spaced points array
* Construct a row array plotPoints with 5 values that are spaced linearly from lowValue to highValue. Ex: If lowValue is 1 and ...

9 years ago

Solved


Relational operators and row arrays: Run times
* Construct a row array fastRunTimes containing all elements of runTimes equal to or less than 480 seconds.

9 years ago

Solved


Comparing floating point values
* Assign matchFound with true if firstSample and secondSample within thresholdValue.

9 years ago

Solved


Double colon operator: Counting up
* Construct a row array countValues from 1 to endValue, using the double colon operator. Ex: If endValue is 5, countValues s...

9 years ago

Solved


Double colon operator: Counting down
* Construct a row array countValues from startValue to endValue, elements decremented by -2 end Ex: If startValue is 10 and ...

9 years ago

Solved


Double colon operator: Increment by x
* Construct a row array countValues from 0 to 25, elements incremented by incrementValue. Ex: If incrementValue is 5, countVa...

9 years ago

Solved


Indexing an array element
* Assign currentStudent with the second element of array testScores.

9 years ago

Solved


Arithmetic array operations
* Add x to each element of array temperatureReadings.

9 years ago

Solved


Union of two set decreasing order
Union of two set decreasing order Say, x=[1 2 5] and y=[5 7 8] then answer must be [8 7 5 2 1]

9 years ago

Solved


Find out magnitude of vector
Find out magnitude of vector. Say x=[1 2 3], then answer must sqrt(1^2+2^2+3^2) Please don't use sum function.

9 years ago

Solved


Column arrays: Transpose a row array
* Construct a row array countValues with elements 1 to endValue, using the double colon operator. * Transpose countValues to re...

9 years ago

Solved


Function definition: Volume of a pyramid
Define a function CalculatePyramidVolume with inputs baseLength, baseWidth, and pyramidHeight. The function returns pyramidVolum...

9 years ago

Solved


Function definition: Double down.
* Complete the DoubleDown function to return twice the initialValue.

9 years ago

Solved


Multi-line comments
* Fix the syntax errors.

9 years ago

Solved


Comments
* Fix the syntax errors.

9 years ago

Solved


Find the mode of the given input
Find the statistical <http://en.wikipedia.org/wiki/Mode_(statistics)/ mode> of the given input. Example: If X is matr...

9 years ago

Load more