Resuelto


Who knows the last digit of pi?
There is only one man who knows the last digit of pi, who is that man? Give the name of that man, who, by popular believe, can ...

alrededor de 1 mes hace

Resuelto


Shorten pathname
Given a pathname string, return a condensed version by replacing intermediate folders with '..'. *Example* If fullpat...

alrededor de 1 mes hace

Resuelto


If-then-else
Complete the function below such that if the value of x is in the range 10 to 14, inclusive, the value 18 is assigned to y. Oth...

alrededor de 1 mes hace

Resuelto


Counting down
Create a vector that counts from 450 to 200 in increments of 10.

alrededor de 1 mes hace

Resuelto


Wind Chill Computation
On a windy day, a temperature of 15 degrees may feel colder, perhaps 7 degrees. The formula below calculates the "wind chill," i...

alrededor de 1 mes hace

Resuelto


All your base are belong to us
Find the base _b_ logarithm of the input decimal number _x_. Express the output as a decimal number. The first argument is the n...

alrededor de 1 mes hace

Resuelto


only input
Return the output without writing any code into the function.

alrededor de 1 mes hace

Resuelto


Who invented zero?
We know the importance zero in computer science, mathematics... but who invented zero? Clue: He was the first in the line ...

alrededor de 1 mes hace

Resuelto


Basic arrays operations.
Apply element-by-element binary operation 'fun' to two arrays (A and B).

alrededor de 1 mes hace

Resuelto


Penny flipping - calculate winning probability (easy)
Two players are playing a fair penny flipping game. For each flip, the winner adds one penny from the loser's collection to his/...

alrededor de 1 mes hace

Resuelto


The Answer to Life, the Universe, and Everything
A variation of a previous Hitchhiker's Guide to the Galaxy problem. *Inputs:* Life, the Universe, and Everything *Output:*...

alrededor de 1 mes hace

Resuelto


Change string to number
Change given string to number. (hint: there is already function) Changing from ['1234'] to [1234] is one of example

alrededor de 1 mes hace

Resuelto


テレビのサイズを求めてみよう
あなたは電気屋で働いています。 あなたの電気屋にテレビを買いに来たお客さんに「何インチのテレビを買いたいのか」と質問したところ、対角線の情報しかわからないと言われてしまいました。 しかし、テレビのインチを知るには、幅と高さの情報が必要です。 ...

alrededor de 1 mes hace

Resuelto


特定の値がベクトル内に含まれているかを確認するコードを書こう
ベクトル b にあるスカラ値 a が含まれていれば出力として 1 を返し、含まれていなければ 0 を返すような関数を作成しましょう。 例: a = 3; b = [1,2,4]; スカラ値 3 はベクトル b に含まれていない...

alrededor de 1 mes hace

Resuelto


Find Logic 4

alrededor de 1 mes hace

Resuelto


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

alrededor de 1 mes hace

Resuelto


Kinetic Energy
Given the mass m and velocity v of an object, determine its <http://en.wikipedia.org/wiki/Kinetic_energy kinetic energy>.

alrededor de 1 mes hace

Resuelto


Count photos
Given n people, everyone must have pictures taken with everyone, each photo includes only two persons, please count the total nu...

alrededor de 1 mes hace

Resuelto


Find the max element of the array
Find the max element of the array

alrededor de 1 mes hace

Resuelto


Back to basics 12 - Input Arguments
Covering some basic topics I haven't seen elsewhere on Cody. Return a value equal to the number of input arguments to the fun...

alrededor de 1 mes hace

Resuelto


Back to basics 4 - Search Path
Covering some basic topics I haven't seen elsewhere on Cody. Return a string that is the user's portion of the current search...

alrededor de 1 mes hace

Resuelto


Volume of a box
Given a box with a length a, width b, and height c. Solve the volume of the box.

alrededor de 1 mes hace

Resuelto


Matlab Basics - Convert a row vector to a column vector
Write a script to convert a row (e.g. x = [1 2 3]) to a column (e.g. y = [1;2;3]), your script should be able to do this for any...

alrededor de 1 mes hace

Resuelto


Beginner's Problem - Squaring
Try out this test problem first. Given the variable x as your input, square it by two and put the result in y. Examples: ...

alrededor de 1 mes hace

Resuelto


First N Perfect Squares
*Description* Return the first N perfect squares *Example* input = 4; output = [ 1 4 9 16 ];

alrededor de 1 mes hace

Resuelto


Volume and area of a sphere
Input(r) - radius Output([v,s]) - volume and area

alrededor de 1 mes hace

Resuelto


Generate a NaN...on purpose
The goal is to create a function that will return a single "NaN" without using the nan function. I am interested to see how many...

alrededor de 1 mes hace

Resuelto


Who is the smartest MATLAB programmer?
Who is the smartest MATLAB programmer? Examples: Input x = 'Is it Obama?' Output = 'Me!' Input x = 'Who ?' Ou...

alrededor de 1 mes hace

Resuelto


Make a 1 hot vector
Make a vector of length _N_ that consists of all zeros except at index _k_, where it has the value 1. Example: Input ...

alrededor de 1 mes hace

Resuelto


Extract a specific part of matrix!
In the given matrix, extract element that have odd rows and column number. For example A=[1 4 2 3 5] B=extractodd(A);...

alrededor de 1 mes hace

Cargar más