Multiply by 3
Given the variable x as your input, multiply it by three and put the result in y.
9年以上 前
解決済み
Y=X
Given an input variable x, output a variable y that is equal in value to x.
Example:
Input x = 1
Output y is 1
Inp...
9年以上 前
解決済み
Add 7
Given an input variable x, output a variable y that is 7 greater than x.
Example:
Input x = 1
Output y is 8
Input ...
9年以上 前
解決済み
only input
Return the output without writing any code into the function.
9年以上 前
解決済み
Create a square matrix of multiples
Given an input, N, output a matrix N x N with each row containing multiples of the first element of each row.
This also applies...
9年以上 前
解決済み
Try 1.5.4: Celsius to Fahrenheit
Write a program to convert an input given in Celsius to Fahrenheit.
Examples:
Input celsiusValue = 100
Output fahrValu...
Back to basics 8 - Matrix Diagonals
Covering some basic topics I haven't seen elsewhere on Cody.
Given an input vector of numbers, output a square array with the...
9年以上 前
解決済み
Fill a zeros matrix
The aim is to fill an array of all zeros given a numerical value and the index of row and columns for this value.
3 Inputs:
...
9年以上 前
解決済み
Expand a term
Given a term, as a string, expand it.
e. g.
f = '2(x + y)';
9年以上 前
解決済み
Calculate some equation
Using given inputs x and z, make two outputs that are
y1 = (xz)/(x/z)^2 + 14x^2 - 0.8z^2
y2 = x^z - z^x + (x/z)^2 - (z/x...
9年以上 前
解決済み
make an eye matrix which element is 1:n
for a given input n, make an n by n matrix which contains elements 1:n
for example
input =5
output = [1 0 0 0 0;0 2 0 0 0; 0...
9年以上 前
解決済み
Smith numbers
Return true if the input is a Smith number in base ten. Otherwise, return false. Read about Smith numbers at <http://en.wikipedi...
9年以上 前
解決済み
Bell Number calculator
Calculate a vector of Bell numbers for sets up to length n. Bell numbers are the maximum number of partitions of a set. See the ...
9年以上 前
解決済み
Evil Number
Check if a given natural number is evil or not.
Read more at <https://oeis.org/A001969 OEIS>.
9年以上 前
解決済み
Find the 9's Complement
Find the 9's complement of the given number.
An example of how this works is <http://electrical4u.com/9s-complement-and-10s-c...
9年以上 前
解決済み
Armstrong Number
Determine whether the given input n-digit number is Armstrong Number or not.
Return True if it is an Armstrong Number. An n-D...
9年以上 前
解決済み
Narcissistic number ?
Inspired by Problem 2056 created by Ted.
In recreational number theory, a narcissistic number is a number that is the sum of ...