Solved


Sum of Squares
Given a vector v of length n, write a MATLAB function to calculate the sum of the squares of its elements.

22 hours ago

Solved


Alternate Arrangement
Determine the ways of arranging 'm' men and 'w' women alternatively in a row of 's' seats. Assumptions : s<m and s<w

22 hours ago

Solved


Even Sum
Calculate the sum of all even numbers between 1 and a given positive integer n. Write a function that takes n as input and retur...

23 hours ago

Solved


Find duplicate number from a vector of size n + 1 containing numbers from 1:n
From a given vector of size n + 1, return the duplicate number. Constraints The vector can only contain numbers from 1 to ...

23 hours ago

Solved


Find cross product of 2 vectors
Find cross product of 2 vectors

1 day ago

Solved


Find sum of alternate numbers in a vector
Find sum of alternate numbers in a vector starting from index 1

1 day ago

Solved


convert 24 hour time to 12 hour time
convert 24 hour time to 12 hour time Input: '13:12' Output: '01:12 PM' Input: '06:12' Output: '06:12 AM'

1 day ago

Solved


Bag of apples
find probabilty of getting red apples from a bag of 'r' red and 'g' green apples.

1 day ago

Solved


Matrix symmetry
Given a matrix A = [1 2 3; 4 5 6] Flip it horizontally and vertically to obtain a complete reversal of both rows and columns. ...

1 day ago

Solved


Determine if input is greater than pi
Evaluate if given number is greater than pi. If greater, return true; else, return false.

1 day ago

Solved


Magnitude with vargin
Return the magnitude (square root of the sum of the squares) for an undefined number of input arguments.

1 day ago

Solved


Build the Well
Calculate the total time taken for building 'n' wells given : Worker A takes a hr to build the well alone Worker B takes b hr...

1 day ago

Solved


Add Odd and Subtract Even Numbers in an Array
For an input array, add all the odd values and subtract the even values. The final value is the output. E.g. input = [1 2 3 4 ...

1 day ago

Solved


Is it the answer to life the universe and everything?
The answer to life the universe and everything is 42, but this is naturally in base 13. Unfortunately, MATLAB is in base 10, so ...

1 day ago

Solved


Find the surface area of a cone.
For instance, Given r (radius) = 3, and s (slant height) = 5: surface area should be 94.

1 day ago

Solved


Determine if input is greater than 100
Evaluate if given number is greater than 100. If greater, return true; else, return false.

1 day ago

Solved


Hemisphere Volume on Top of a Cylinder
This MATLAB function has to calculate the volume of a hemisphere placed on top of a cylinder, given valid inputs. It takes the r...

1 day ago

Solved


Array Width (no usage of size)
Find the array width. Size may not be used.

1 day ago

Solved


Array Height (no usage of size)
Find the array height, the number of rows. Size may not be used.

1 day ago

Solved


A row vector, pick 1st number, skip 1,pick 3rd number, skip 2,pick,skip,etc then place all picked numbers in order in new vector
Having a row vector of number, pick the first number, place in new output vector as the first value, then skip one number, pick...

1 day ago

Solved


Summing the last column column
Given a matrix, return the sum of the last column of the array.

1 day ago

Solved


Lancer de dés
Ecrire une fonction qui imite le lancer d'un dé, i-e qui renvoie de façon aléatoire un entier entre 1 et 6. Attention cette fon...

1 day ago

Solved


Count integers in randomized vector that are multiples of a given number.
The mod() function We might all remember the days when we were taught to divide and then set the remainder aside if the numbers...

1 day ago

Solved


Find mass of single floor in building
A model building has three floors are highlighted in different colours here: Assu...

1 day ago

Solved


rotation et mise à l'échelle avec des complexes
Ecrire une fonction Zr=scale_rot(A,phi,Z) qui permet une mise à l'échelle d'un facteur A et une rotation d'un angle phi (en rad)...

1 day ago

Solved


Free passes for everyone!
_Simply return the name of the coolest numerical computation software ever_ *Extra reward* (get a _freepass_): Once a mont...

1 day ago

Solved


Palindrome String
Determine if the inputted string is a palindrome. That is, the string is the same forwards as it is backwards. For example: ...

2 days ago

Solved


Palindrome vector
Check if a given vector is Palindrome. Example, [1 2 54 32 45 5 33 456 45 456 33 5 45 32 54 2 1]

2 days ago

Solved


Determine if a number is a cool number
A number is considered cool if it is 3 digits, has a 5 in it, and is divisible by 4.

2 days ago

Solved


nxn matrix with elements from 1:n^2
really simple once you see what the matrix is supposed to look like. i appreciate what seems to be a clever approach to solving ...

2 days ago

Load more