Risolto


Create sequnce 1 4 9 16 25.........
Create sequnce 1 4 9 16 25......... upto entered input value using matlab scripting commands. Let y be output and x be input

quasi 8 anni fa

Risolto


Area of rhombus
Calculate the rhombus area

quasi 8 anni fa

Risolto


matrix of natural number
Given a number n, create an n-by-n matrix in which the integers from 1 to n^2 resides seially as shown in the examples below. ...

quasi 8 anni fa

Risolto


Matlab Basics II - Count rows in a matrix
Write a function that returns that number of rows in a vector or matrix x example: x = [1; 2; 3] output = 3

quasi 8 anni fa

Risolto


Find the product of a Vector
How would you find the product of the vector [1.0 1.5 2.0 2.5 3.0 3.5 4.0 4.5 5.0 5.5 6.0] times 2?; x = [1 : 0.5 : 6]; y ...

quasi 8 anni fa

Risolto


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

quasi 8 anni fa

Risolto


Square Diagonal
If n is the given number, then make a diagonal matrix of size 2*2 with the square of that number.

quasi 8 anni fa

Risolto


BASICS - sum part of vector
Please make a function, where as input you get vector "x" and and vector "c", where in "c" vector you get indexes to sum. Examp...

quasi 8 anni fa

Risolto


Sudoku square
We have a small Sudoku square, but one number is missing. x = [ 1 5 4 8 6 3 0 9 7 ] Make a function, wher...

quasi 8 anni fa

Risolto


Remove the first, third and fifth rows of a matrix
Given a matrix x with at least five rows, return a matrix y that includes all rows of x except for th 1st, the 3rd and 5th. E...

quasi 8 anni fa

Risolto


Matlab Basics II - Free Fall
An object freely falling from rest under gravity covers a distance x given by: x = 1/2 gt^2 write a function that calculat...

quasi 8 anni fa

Risolto


Times 3 problem
When you enter the number, it should return the number multiplied by 3

quasi 8 anni fa

Risolto


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

quasi 8 anni fa

Risolto


Matlab Basics - Logical Tests I
Write a script to test whether a year number is for a leap year or not. eg. x = 1884 output = 1 eg. x = 3 output = 0

quasi 8 anni fa

Risolto


factorial of a number x
Factorial of a number x

quasi 8 anni fa

Risolto


y equals x divided by 2
function y = x/2

quasi 8 anni fa

Risolto


Area of a circle
Given the radius x, y would be the area of a circle. Pi = 3.1416

quasi 8 anni fa

Risolto


Find the logic
There exists one logic in between input and output. Find it (easy math). Example 1: x=13 then y=339; Example 2: x=26...

quasi 8 anni fa

Risolto


Test Problem; Create a 5x5 array containing all ones
This is a test for learning the process of creating a Cody problem. The goal of this test problem will be to create an array,...

quasi 8 anni fa

Risolto


Finding perimeter of a rectangle
A rectangle has a length of x centimeters and a width of w centimeters. Find the perimeter.

quasi 8 anni fa

Risolto


Sum of Two Numbers
Given two integer numbers x and y, calculate their sum and put it in z. Examples: Inputs x = 2, y = 4 Output z is 6 ...

quasi 8 anni fa

Risolto


Matlab Basics - Pick out parts of a vector
Consider x a vector of length >= 7 (there are at least 7 elements in the vector, write a script that extracts the 2nd element, a...

quasi 8 anni fa

Risolto


Square the input
Given a scalar or vector x, return the square of each element. Example x = [7 2] answer = [49 4]

quasi 8 anni fa

Risolto


Returning a "greater than" vector
Given a vector, v, return a new vector , vNew, containing only values > n. For example: v=[1 2 3 4 5 6] n=3 vNew =...

quasi 8 anni fa

Risolto


Binary Coder
Take an input number and print the binary value of this number.

quasi 8 anni fa

Risolto


Find the area of a triangle
Given a triangle with a base b and height h, return the triangle area.

quasi 8 anni fa

Risolto


Calculate square and cube of number
Calculate square and cube of number x

quasi 8 anni fa

Risolto


Find the Nth Root of a Given Number
Find the Nth root of a given number x. Examples x = 4096 n = 4 y = 8 x = 625 n = 5 y = 3.6239

quasi 8 anni fa

Risolto


What's size of TV?
Many people buy TV. Usually they ask about diagonal. But also important are width and height. Let's assume that all TV have rati...

quasi 8 anni fa

Risolto


Speed of car
Calculate the Speed of car given its Distance travelled and time taken in x and y respectively

quasi 8 anni fa

Carica altro