A résolu


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.

2 mois il y a

A résolu


Complete hydraulic geometry relations
Hydraulic geometry relations express the velocity , width , and depth of a river as a function of the discharge (or flow) , whi...

2 mois il y a

A résolu


Pythagorean perfect squares: find the square of the hypotenuse and the length of the other side
Given the square root of a square number, *seed*, and a range, *n*, find the square number, *Z* as well as the other side, *y*, ...

2 mois il y a

A résolu


Find left eigenvector of row stochastic matrix
Find the left eigenvector of the given stochastic matrix P that has eigenvalue 1. Normalize the vector so the sum of the entri...

2 mois il y a

A résolu


Effective Nuclear Charge

2 mois il y a

A résolu


ICFP2024 005: Lambdaman 1, 2, 3
The ICFP2024 contest was held June29 thru July 1. The contest consisted of five parts: ICFP Language, Lambdaman maze, Starship f...

2 mois il y a

A résolu


Convert array of decimal numbers into binary numbers array.
Convert an array of decimal numbers into binary numbers array. For example: x = [1 2 3 4 5 6 7 8]; result = [1; 10; 11;...

2 mois il y a

A résolu


Calcular la razón de proporcionalidad
Dadas dos magnitudes (a y b) en forma de vectores, crear una función que permita obtener la razón de proporcionalidad _*m*_ sólo...

2 mois il y a

A résolu


Unique - Very Very Large Numbers
Given a vector column, with some very large numbers, create the ascending sort and unique vector. *Input:* A (column vector)...

2 mois il y a

A résolu


Replace odd number in given matrix by zero
Replace the odd numbers in a given matrix with zero. Example A = [ 17 24 1 8 15 23 5 7 ...

2 mois il y a

A résolu


Is My Wife Wrong?
Answer the question. (see also <http://www.mathworks.com/matlabcentral/cody/problems/149-is-my-wife-right Problem 149: Is my ...

2 mois il y a

A résolu


Replace secondary diagonal elements of a square array
Replace all the secondary diagonal elements of the square array A with the number n Example: A = [1 2 3 4 5 6 ...

2 mois il y a

A résolu


Say type of roots in quadratic equation
Given the coefficients of a quadratic equation, write a function that gives the output y='RealDifferent' if the roots are real a...

2 mois il y a

A résolu


Determine the roots of a cubic equation
Given the coefficients a, b, c, and d of a cubic equation, a*x^3 + b*x^2 + c*x + d = 0, determine its roots.

2 mois il y a

A résolu


Basic Monte Carlo Simulation
Input is a matrix including service time and probability of service time. Another input is a random number. Function should tran...

2 mois il y a

A résolu


The last non-zero digit of a factorial
For given positive integer n, what is the last non-zero digit of n!? Example: factorial(11) = 39916800 Last non-zero d...

2 mois il y a

A résolu


Nth Order Polynomial Regression
Inputs: -two vectors x and y (row or column) -order of polynomial, p Outputs: -vector of coefficients [b0 b...

2 mois il y a

A résolu


Grouped Frequency Distributions

2 mois il y a

A résolu


ICFP2024 006: Lambda 21 - 3D
The ICFP2024 contest was held June29 thru July 1. The contest consisted of five parts: ICFP Language, Lambdaman maze, Starship f...

2 mois il y a

A résolu


Find the mean of a 2-D matrix after excluding elements of specified sub-matrix
You need to find the mean of a 2-D matrix after excluding elements which form an inner sub-matrix. e.g. If the input 2-D matrix ...

2 mois il y a

A résolu


Determine ground distance from an aircraft to a DME station
In aviation, distance measuring equipment (DME) uses radio signals to determine slant distance from an aircraft to a ground stat...

2 mois il y a

A résolu


Cumulative product of a vector
Cumulative product of a vector example x=[1 2 5 10], then answer must be [ 1 2 10 100] *If you like this prob...

2 mois il y a

A résolu


Number of Circles in a Number
Given a number, return the number of closed 'circles' in the base 10 numerical representation. Note: the number 4 has no circ...

2 mois il y a

A résolu


Case-insensitive Character Detection
Find the index of a particular character in a string ignoring case. Example Input: x = 'aAbhhfdf' n = 'a' ...

2 mois il y a

A résolu


Fibonacci Sequence
Write a MATLAB function called fibonacci_sequence(n) that takes an integer n as input and returns the first n terms of the Fibon...

2 mois il y a

A résolu


Convolution Power
Create the convolution-power vector from initial vector _x_ and power _n_. In other words, similar to the scalar case, raising ...

2 mois il y a

A résolu


count upper and lower case characters
In a given input string, count and return the number of upper and lower case characters as u and l respectively. For example:...

2 mois il y a

A résolu


How to permute given 3d matrix?
A(:,:,1)=[1 3] A(:,:,2)=[2 2] A(:,:,3)=[4 3] Change rows to columns and columns to rows, similar to transpose. Resul...

2 mois il y a

A résolu


Recursion at variable input
input of any length a =2 b =2 c =3 output = (a^b)^c = 64

2 mois il y a

A résolu


Squares of odd numbers upto a given range
Find the squares of odd numbers upto a given range. If Given x=6 return y=(1^2,3^2,5^2) y=1,9,25 If Given x=5 retu...

2 mois il y a

Charger plus