1,329 total contributions since 2016

Professional Interests: Model-Based Design

Solved

Calculate Resistance 2

In this problem, you have to calculate Resistance R of a linear conductor having voltage V across it and current I is passing i...

5 days ago

Solved

Determine the length of a string of characters

Determine the length of a string of characters

10 days ago

Solved

find the relation...

if given input is 1, output is 4. if input is 55, output is 3136.

10 days ago

Solved

Doubling elements in a vector

Given the vector A, return B in which all numbers in A are doubling. So for: A = [ 1 5 8 ] then B = [ 1 1 5 ...

17 days ago

Solved

Calculate Resistance

Calculate Resistance R of a linear conductor having resistivity p, length l and area A

1 month ago

Solved

Add 3 numbers

In this problem, you have to add three numbers a, b and c. Give output d = add(a,b,c)

1 month ago

Solved

Scalar Matrix Manipulation

Assume, input x is a scalar matrix such as, x = 2 0 0 0 2 0 0 0 2 th...

2 months ago

Solved

Cody problems in French : Trouvez la logique Pt.2

Trouvez la logique entre x et y, aidez-vous de la test suite. Bon courage. P.S: L'utilisation de "^" est de nouveau fortement...

2 months ago

Solved

Just another sum (JAS)

*Task:* Write a function that takes a vector X and returns the alternating sum of X: X(1)-X(2)+X(3)-X(4)+... *Example...

2 months ago

Solved

Double the next!

Given two numbers, m and n, find a matrix m x n where each element value is twice the value of the previous element. Starting fr...

3 months ago

Solved

Determine if input is odd or even

Determine if input is odd or even, sample problem

3 months ago

Solved

Calculate the square of a number (Super Easy)

The goal is to calculate the square (y) of a number (x). Good way to start MatLab for beginners.

3 months ago

Solved

Add consecutive integer numbers

Given consecutive numbers, add the numbers *without using the sum command in MATLAB.*

4 months ago

Solved

Binary code (array)

Write a function which calculates the binary code of a number 'n' and gives the result as an array(vector). Example: Inpu...

4 months ago

Solved

Binary

Given a positive, integer n, create a function that returns the respective binary number in the form of a vector. Example: ...

4 months ago

Solved

Flip the bit

Given an input character string (e.g. '1001'), return a character string with the bits flipped ('0110').

4 months ago

Solved

Find the complement of a number in binary

Input x is a decimal number and output y is the complement of binary representation of x. For example, x = 10 has the binary ...

4 months ago

Solved

No Twins?

Write a function that accepts as input a vector and returns the same vector, but retaining only the first occurrence of an eleme...

4 months ago

Solved

Number of 1s in a binary string

Find the number of 1s in the given binary string. Example. If the input string is '1100101', the output is 4. If the input stri...

4 months ago

Solved

Return the first and last character of a string

Return the first and last character of a string, concatenated together. If there is only one character in the string, the functi...

4 months ago

Solved

You never ask a lady her age

Instead you ask her to multiply her age by 10, then subtract any of the first nine multiples of 9 (9,18,...,81), and tell you th...

4 months ago

Solved

Optimization of cylinder surface area

Optimization of a cylinder surface area. What are the best parameters (radius and height) to get the minimum cylinder surface a...

4 months ago

Solved

Draw 'B'

Draw a x-by-x matrix 'B' using 1 and 0. (x is odd and bigger than 4) Example: x=5 ans= [1 1 1 1 0 1 0 0 0 1 ...

4 months ago

Solved

Draw 'I'

Given n as input, draw a n-by-n matrix 'I' using 0 and 1. example: n=3 ans= [0 1 0 0 1 0 0 1 0] n=...

4 months ago

Solved

Cube root of max value in a vector

Find the cube root of the maximum value in a vector

4 months ago

Solved

Cannibal eating odd and even numbered men

There are N men in a queue. A cannibal eats either all odd-numbered or all even-numbered men in the queue at a time. In the fi...

5 months ago