A résolu


Matlab Basics - Set unwated parts of a vector to zero
Consider a vector x, of length >= 7, write a script to set elements 2, 5, and 6 to zero. e.g. x = [1 2 3 4 5 6 7] --> x = [1 ...

presque 11 ans il y a

A résolu


print date for a given number in date reference is INDIAN calendar,not Christ's Birth.
The Vikram Samvat is said to have been founded by the emperor Vikramaditya of Malwa following his victory over the Sakas in 56 Y...

presque 11 ans il y a

A résolu


For a given linear index as input for n sized square matrix, find corresponding row and column.
If input is 1, the row and column will be 1 and 1 respectively.

presque 11 ans il y a

A résolu


Is it column vector?
Is it column vector? Check vector for column vector without using iscolumn function.

presque 11 ans il y a

A résolu


replace empty matrices with '[]'
for example a=1;a(:,1)=[]; returns a = Empty matrix: 1-by-0 use this as the input,and the output should be '[]...

presque 11 ans il y a

A résolu


Get all corner elements from a matrix where dimension of matrix is always equal to or greater than 2.
if a given matrix a = [1 2 3;4 5 6]; so answer is going to be [1 3;4 6]

presque 11 ans il y a

A résolu


Replacing a row
For matrix G=[1 2 3; 4 5 6; 7 8 9] Replace the 2nd row with 8s **remember to create matrix G

presque 11 ans il y a

A résolu


Elapsed time is -0.005204 seconds.
Write a function that takes less than zero seconds to execute, as measured using tic and toc. For repeatability, the test case p...

presque 11 ans il y a

A résolu


We love vectorized solutions. Problem 1 : remove the row average.
Given a 2-d matrix, remove the row average from each row. Your solution MUST be vectorized. The solution will be tested for ac...

presque 11 ans il y a

A résolu


Calculate the height of an object dropped from the sky
Assume that an object is dropped from 1000 meters above the surface of the earth at time t=0. The object is dropped such that t...

presque 11 ans il y a

A résolu


What is the distance from point P(x,y) to the line Ax + By + C = 0?
Given a point, P(x,y), find the distance from this point to a linear line. INPUTS: x, y, A, B, C OUTPUTS: d, the distance ...

presque 11 ans il y a

A résolu


Who am I ?
Who am I ? Write any function that reveals itself under these constraints. Hint: I am combinatorial code, and I don't like stat...

presque 11 ans il y a

A résolu


Replace all zeros and NaNs in a matrix with the string 'error'
Given a numeric input matrix A, possibly containing some zero values and some NaNs, replace any occurrences of zero or NaN with ...

presque 11 ans il y a

A résolu


Roots
Find out the roots of a given polynomial equation.Given are the coefficients of the equation.

presque 11 ans il y a

A résolu


Conic equation
A conic of revolution (around the |z| axis) can be defined by the equation s^2 – 2*R*z + (k+1)*z^2 = 0 where |s^2=x^2+y...

presque 11 ans il y a

A résolu


calculate Compound Intrest
Calculate Compound Intrest for given data

presque 11 ans il y a

A résolu


check whether it is prime or not
Given a number,check whether it is prime or not. If prime output is true else false

presque 11 ans il y a

A résolu


Calculate Simple Intrest for given data
P,N,R stands for Principle amount, No. of years and rate of intrest resp. Calculate intrest I

presque 11 ans il y a

A résolu


Rank of matrix
Find the rank of given matrix

presque 11 ans il y a

A résolu


Currency conversion
A currency exchange booth offers an exchange rate of 119.771 Japanese yen for 1 US dollar. The currency exchange booth rounds do...

presque 11 ans il y a

A résolu


Compute change
A cashier distributes change using the maximum number of five dollar bills, followed by one dollar bills. Given amountToChange, ...

presque 11 ans il y a

A résolu


Health app
A health app records a user's weight and displays the change in weight from the previous measurement to the next. Assign weightC...

presque 11 ans il y a

A résolu


Forward difference approximation: Car temperatures
Column arrays measuredTemperature and sampleTime contain engine temperature measurement samples, and the time each sample was co...

presque 11 ans il y a

A résolu


Sum function: Counting cookies
Row array troopCookieSales contains the number of boxes of cookies sold by each troop member. Assign totalSales with the sum of ...

presque 11 ans il y a

A résolu


Left Riemann numerical integration
A curve is represented by column arrays xCoordinate and yCoordinate. Approximate the integral from xCoordinate(1) to xCoordinate...

presque 11 ans il y a

A résolu


Luggage delivery
Assign deliveryCost with the cost to deliver a piece of baggage weighing baggageWeight. The service charges twenty dollars for ...

presque 11 ans il y a

A résolu


Assignment statements based on input value
Write an if-else statement that assigns finalValue with userValue + 5 if userValue is greater than 100. Otherwise assign finalVa...

presque 11 ans il y a

A résolu


Bridge toll
Complete the example to calculate finalToll. The base toll for a bridge is baseToll. If the vehicle's weight is over 5,000 pound...

presque 11 ans il y a

A résolu


Equality check: Number of bricks
Write an if statement that assigns deliveryComplete with 1 if bricksDelivered is equal to bricksExpected.

presque 11 ans il y a

A résolu


Small aircraft weight limit
Write an if-else statement that evaluates to true if the sum of passengerWeight and cargoWeight is less than or equal maxWeight....

presque 11 ans il y a

Charger plus