Community Profile

photo

AGAM GUPTA_786


Nit patna

2014년부터 활동

Followers: 0   Following: 0

연락

통계

  • Commenter
  • Promoter
  • CUP Challenge Master
  • Solver

배지 보기

Feeds

보기 기준

문제를 풀었습니다


Distance walked 1D
Suppose you go from position 7 to 10 to 6 to 4. Then you have walked 9 units of distance, since 7 to 10 is 3 units, 10 to 6 is 4...

대략 9년 전

문제를 풀었습니다


Create times-tables
At one time or another, we all had to memorize boring times tables. 5 times 5 is 25. 5 times 6 is 30. 12 times 12 is way more th...

대략 9년 전

문제를 풀었습니다


Finding Perfect Squares
Given a vector of numbers, return true if one of the numbers is a square of one of the other numbers. Otherwise return false. E...

대략 9년 전

문제를 풀었습니다


Fahrenheit to Celsius using multiple statements
Given a Fahrenheit value F, convert to a Celsius value C. While the equation is C = 5/9 * (F - 32), as an exercise use two state...

대략 9년 전

문제를 풀었습니다


How to find the position of an element in a vector without using the find function
Write a function posX=findPosition(x,y) where x is a vector and y is the number that you are searching for. Examples: fin...

대략 9년 전

문제를 풀었습니다


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

대략 9년 전

문제를 풀었습니다


Fibonacci sequence
Calculate the nth Fibonacci number. Given n, return f where f = fib(n) and f(1) = 1, f(2) = 1, f(3) = 2, ... Examples: Inpu...

대략 9년 전

문제를 풀었습니다


Swap the first and last columns
Flip the outermost columns of matrix A, so that the first column becomes the last and the last column becomes the first. All oth...

대략 9년 전

문제를 풀었습니다


Column Removal
Remove the nth column from input matrix A and return the resulting matrix in output B. So if A = [1 2 3; 4 5 6]; and ...

대략 9년 전

문제를 풀었습니다


Triangle sequence
A sequence of triangles is constructed in the following way: 1) the first triangle is Pythagoras' 3-4-5 triangle 2) the s...

대략 9년 전

문제를 풀었습니다


Reverse the vector
Reverse the vector elements. Example: Input x = [1,2,3,4,5,6,7,8,9] Output y = [9,8,7,6,5,4,3,2,1]

9년 초과 전

문제를 풀었습니다


Determine whether a vector is monotonically increasing
Return true if the elements of the input vector increase monotonically (i.e. each element is larger than the previous). Return f...

9년 초과 전

문제를 풀었습니다


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.

9년 초과 전

문제를 풀었습니다


Weighted average
Given two lists of numbers, determine the weighted average. Example [1 2 3] and [10 15 20] should result in 33.333...

9년 초과 전

문제를 풀었습니다


vector to string
Determine what the ASCII characters spell out. Example: input = [ 72 73 71 72] output = 'HIGH'

9년 초과 전

문제를 풀었습니다


Too mean-spirited
Find the mean of each consecutive pair of numbers in the input row vector. For example, x=[1 2 3] ----> y = [1.5 2.5] x=[1...

9년 초과 전

문제를 풀었습니다


Pizza value using expression with parentheses
Pizza prices are typically listed by diameter, rather than the more relevant feature of area. Compute a pizza's value (cost per ...

9년 초과 전

문제를 풀었습니다


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

9년 초과 전

문제를 풀었습니다


Sum of diagonal of a square matrix
If x = [1 2 4; 3 4 5; 5 6 7] then y should be the sum of the diagonals of the matrix y = 1 + 4 + 7 = 12

9년 초과 전

문제를 풀었습니다


Logic variables
* Assign isAvailable with true.

9년 초과 전

문제를 풀었습니다


Declaring a character
* Assign middleInitial with the character T.

9년 초과 전

문제를 풀었습니다


Write an expression
Assigns finalResult with firstSample plus secondSample, divided by 3. Ex: If firstSample is 18 and secondSample is 12, finalResu...

9년 초과 전

문제를 풀었습니다


Declaring a string
* Assign streetAddress with the string 1313 Mockingbird Lane.

9년 초과 전

문제를 풀었습니다


Circle area using pi
Write a statement that assigns circleArea with the circle's area given circleRadius. Use the built-in mathematical constant pi. ...

9년 초과 전

문제를 풀었습니다


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

9년 초과 전

문제를 풀었습니다


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

9년 초과 전

문제를 풀었습니다


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

9년 초과 전

문제를 풀었습니다


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

9년 초과 전

문제를 풀었습니다


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

9년 초과 전

문제를 풀었습니다


Assigning a sum
* Write a statement that assigns numCoins with numNickels + numDimes.

9년 초과 전

더 보기