A résolu


Intersection points of a polynomial
Find the intersection points of a polynomial, given by its vector of coefficients with the X-axis and the Y-axis. Input: a poly...

environ 2 mois il y a

A résolu


What kind of triangle?
Write a function named check_triangle that receives three positive integers as input: a, b, and c. These three numbers are inte...

environ 2 mois il y a

A résolu


Sum of Even Numbers in a Vector
Write a function that takes a vector x as input and returns the sum of all even numbers in x. Input: x = [1, 2, 3, 4, 5, 6] ...

environ 2 mois il y a

A résolu


Area under standard normal curve

environ 2 mois il y a

A résolu


Check p² = 24k + 1, p > 3, the 'golden prime squares' equation
Historical context In december 2023, I / Nicolas Douillet was working on prime squares properties and I found* the formula : ...

environ 2 mois il y a

A résolu


Define the operators of function_handles
Suppose f and g are function_handles, try to define f+g,f-g,f*g and f/g. e.g. if f = @(x)x and g = @(x)x+1 ...

environ 2 mois il y a

A résolu


Frequencies of prime gaps
Problem statement Given two positive integers n and , write a function which computes the frequency of the gap between two ...

environ 2 mois il y a

A résolu


String permutations on phone keyboard
Given a number such as 2639 return all possible string permutations using the phone-keyboard on Problem 1069. input = 78 outpu...

environ 2 mois il y a

A résolu


Decrypt a secret message!
The crypto system in question is based on phone keyboard. We need two numbers in order to decrypt a word. First number represent...

environ 2 mois il y a

A résolu


Extra colors
Context In the RGB color system used by Matlab, the color is a 1 x 3 / row vector [R G B] with each value/component R, G, B in ...

environ 2 mois il y a

A résolu


Create co-occurrence matrix

environ 2 mois il y a

A résolu


Create formatted value string Cell array of a vector
This Challenge is to create a cell array that contains strings of vector components in a given format. c=vector2formattedstri...

environ 2 mois il y a

A résolu


Get the variable value from a string and generate sum
Get the variable value from a string. Example. x = 'A=10' y = 'B=20' Result = (x+y) Result = 30

environ 2 mois il y a

A résolu


Add non-triangular numbers
The nth triangular number is the sum of the first n positive integers. The sequence of triangular numbers starts 1, 3, 6, 10, 15...

environ 2 mois il y a

A résolu


Compute Khinchin's constant
Khinchin's constant K_0 = 2.684542001... (also written "Khintchine's constant") has the amazing property that it is the limiting...

environ 2 mois il y a

A résolu


TingTing
Output logical "true" if the input is the answer to luck and money$$$. Otherwise, output logical "false".

environ 2 mois il y a

A résolu


Functionality 1
It's all about functionality. *Cheating is allowed but not required*

environ 2 mois il y a

A résolu


Write a code to implement the improved Euler's method to integrate a simple function
Euler's method approximates the solution to a differential equation as where . It's possible to improve on Euler's method by ...

environ 2 mois il y a

A résolu


Orthogonalize 3 column vectors using the Gram-Schmidt process
Use the Gram-Schmidt process to orthogonalize three linearly independent column vectors. Return three output column vectors that...

environ 2 mois il y a

A résolu


A "Complex" Converter: Rectangular Form <-> Polar Form
*BACKGROUND / MOTIVATION:* Complex numbers can be an important tool in an electrical engineer's toolbox because they can help...

environ 2 mois il y a

A résolu


Orthogonalize a 2x2 matrix using the Gram-Schmidt process
Use the Gram-Schmidt process to orthogonalize two linearly independent column vectors. Return two output column vectors that are...

environ 2 mois il y a

A résolu


Multiplying the Sums of Two Arrays
Get two arrays, add the values within the array up, and then multiply the two total values. [2,3]*[3,6] 5*18 90

environ 2 mois il y a

A résolu


Write a code to implement Euler's method to integrate a simple function
Euler's method approximates the solution to a differential equation as where . The challenge is to write a code that can take...

environ 2 mois il y a

A résolu


Neural Net: Back Propagation of Quad Output with Bias, ReLU
This challenge is to return the WH_delta and WP_delta, given X, WH, WP, EPY using ReLU on the hidden layer and Softmax on the ou...

environ 2 mois il y a

A résolu


birthday on same day of week
Say, Mr. X's birthday is on 20th July, 2014. It was Sunday. Determine the closest year when his birthday will again be on Sunday...

environ 2 mois il y a

A résolu


Latest Question On Cody
Get the problem number of the latest submitted Problem on Cody. Copying the test suite code might not help.

environ 2 mois il y a

A résolu


Is it Possible? ( Easy )
In the first part of series, we simplify the problem. Given two jugs with capacities A and B, and a target amount T, determine i...

environ 2 mois il y a

A résolu


Remove the diagonal of a square matrix
Some Cody problems ask solvers to remove columns (e.g., CP 7), and others ask solvers to remove rows (e.g., CP 44033). Write a...

environ 2 mois il y a

A résolu


The Secret Code of Mars
NASA has intercepted a mysterious signal from Mars filled with random letters and numbers. Scientists believe each number in the...

environ 2 mois il y a

Charger plus