Sum all integers from 1 to 2^n
Given the number x, y must be the summation of all integers from 1 to 2^x.
For instance if x=2 then y must be 1+2+3+4=10.
How many Integers?
Count the integers in a given vector |v|.
You *must* use a loop to count each element separately.
Examples:
Input: v...
5 years ago
Solved
Product of Each Column
Given a matrix |mat| with |n| columns, return a row vector |v| of length |n|, where every element in |v| is the product of the |...
5 years ago
Solved
Sum of Two Numbers
Given two integer numbers x and y, calculate their sum and put it in z.
Examples:
Inputs x = 2, y = 4
Output z is 6
...
5 years ago
Solved
Convert yards to feet
The goal of this script is to convert a value given in yards to feet.