Implement simple rotation cypher
If given a letter from the set:
[abc...xyz]
and a shift, implement a shift cypher.
Example:
'abc'
with a shi...
約6年 前
解決済み
Finding Perfect Squares
Given a vector of numbers, return true if one of the numbers is a square of one of the other numbers. Otherwise return false.
E...
約6年 前
解決済み
Remove the vowels
Remove all the vowels in the given phrase.
Example:
Input s1 = 'Jack and Jill went up the hill'
Output s2 is 'Jck nd Jll wn...
約6年 前
解決済み
Check if number exists in vector
Return 1 if number _a_ exists in vector _b_ otherwise return 0.
a = 3;
b = [1,2,4];
Returns 0.
a = 3;
b = [1,...
約6年 前
解決済み
Remove all the consonants
Remove all the consonants in the given phrase.
Example:
Input s1 = 'Jack and Jill went up the hill';
Output s2 is 'a ...
約6年 前
解決済み
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...
約6年 前
解決済み
Find a Pythagorean triple
Given four different positive numbers, a, b, c and d, provided in increasing order: a < b < c < d, find if any three of them com...
約6年 前
解決済み
Return the 3n+1 sequence for n
A Collatz sequence is the sequence where, for a given number n, the next number in the sequence is either n/2 if the number is e...
約6年 前
解決済み
Area of a triangle
A triangle is given with base *'b'* ,vertical hight *'h'* . then find it's area.
約6年 前
解決済み
multiply by three
Given the variable x as your input, multiply it by 3 and put the result equal to y.
Examples:
Input x = 2
Output y is ...
約6年 前
解決済み
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:
...
Given area find sides
In a right angle triangle given area 'A'
one arm=x, another arm=2x
then find the value of x.
For example, area A=400 then ...
約6年 前
解決済み
Convert Fahrenheit to Celsius
Calculate the Celsius temperature C given the Fahrenheit temperature F.
Examples:
Input F = 90
Output C is 32.22
I...
約6年 前
解決済み
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...
約6年 前
解決済み
Length of the hypotenuse
Given short sides of lengths a and b, calculate the length c of the hypotenuse of the right-angled triangle.
<<http://upload....