已解决


Perfect square.
Determine if the input is a perfect square or not. Example - If input is 25, return 1. If input is 17, return 0.

6 years 前

已解决


Usage of java.math : Add, Multiply, Pow
This challenge is an introduction to the wonderful word of java.math that allows unlimited precision calculations. The primary ...

6 years 前

已解决


surrounded matrix
With a given matrix A (size m x n) create a matrix B (size m+2 x n+2) so that the matrix A is surrounded by ones: A = [1 2 ...

6 years 前

已解决


Make your own Test Suite (part 0)
In this task you need to imagine that you — _yes, YOU_ — have developed a problem on Cody for _me_ to solve, and now *you need t...

6 years 前

已解决


Choose the best fitting dominoes
You will be given a cell array of nx2 matrices. Choose one row from each matrix. These are the ordered pairs that will be plac...

6 years 前

已解决


Get 1-4-3-4-4
Get the value of the indices in the title and assign it to an array

6 years 前

已解决


Number of primes
Count the number of primes less than 'n'.

6 years 前

已解决


Clamper Function
Create a function that emulates a clamper circuit Given sin wave, t and the constant value for clamping

6 years 前

已解决


Convert decimal to binary and then generate the minimum binary it can with jumbling
input is 10 --> 1010 output should be 3 --> 0011 input 23 --> 10111 output should be 15 --> 01111

6 years 前

已解决


How many bottles can you drink?
Sometimes if you buy a drink in a glass bottle you can return that bottle and get some money back. Let's assume we have "x" a...

6 years 前

已解决


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

6 years 前

已解决


Basic commands - Least common multiple
Make a function which will return least common multiple of "a" and "b" Example: a=8; b=6; y=24;

6 years 前

已解决


Basic commands - Greatest common divisor
Please write a function, which, will put as output greatest common divisor. Example: A = [-5 17; 10 0];...

6 years 前

已解决


Basic commands - rounding
make a function which will round to integer, which is nearer to zero. Example x=[-2.5 2]; y=[-2 2];

6 years 前

已解决


cross in array
Make a cross from "1" in odd size array. Other value from array should be equal to "0"; As input you get length of side of arra...

6 years 前

已解决


Find best placement for ordered dominoes (harder)
Given a list of ordered pairs, find the order they should be placed in a line, such that the sum of the absolute values of the d...

6 years 前

已解决


Find best domino orientation
Given a list of pairs, find the orientation they should be placed in a line, such that the sum of the absolute values of the dif...

6 years 前

已解决


Find perfect placement of non-rotating dominoes (easier)
Given a list of ordered pairs, find the order they should be placed in a line, such that the sum of the absolute values of the d...

6 years 前

已解决


Rotate and display numbered tile
Imagine a square tile with four numbers on it, one on each edge. We will call these edges north, east, south, and west. If th...

6 years 前

已解决


Stuff the Board
You have a stack of tiles to put onto an array-like playing board. Each tile has a number (always an integer), and the board var...

6 years 前

已解决


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

6 years 前

已解决


Nth root of a number
Given an input and a number N, find the Nth root of the number(s)

6 years 前

已解决


Dial Up
Each number on telephone keypads, except 0 and 1, corresponds to a set of uppercase letters as shown in this list: 2 ABC, 3 DEF...

6 years 前

已解决


Scoring for oriented dominoes
Given a list of ordered pairs, and the order they should be placed in a line, find the sum of the absolute values of the differe...

6 years 前

已解决


Create logical matrix with a specific row and column sums
Given two numbers *|n|* and *|s|*, build an |n-by-n| logical matrix (of only zeros and ones), such that both the row sums and th...

6 years 前

已解决


Return a list sorted by number of consecutive occurrences
Inspired by Problem 38 by Cody Team. Given a vector x, return a vector y of the values in x sorted by the number of CONSECUTIVE...

6 years 前

已解决


Put two time series onto the same time basis
Use interpolation to align two time series onto the same time vector. This is a problem that comes up in <http://www.mathwork...

6 years 前

已解决


"Low : High - Low : High - Turn around " -- Create a subindices vector
Let two vectors *lo* and *hi* be given. The job is to create a index vector like so idx = [lo(1):hi(1) lo(2):hi(2) ...]...

6 years 前

已解决


Joining Ranges
You are given a n-by-2 matrix. Each row represents a numeric range, e.g. x = [0 5; 10 3; 20 15; 16 19; 25 25] contains...

6 years 前

问题


Computational power of Cody servers
It has been <https://en.wikipedia.org/wiki/Moore%27s_law#History predicted> that the performance of integrated circuits would _d...

6 years 前 | 0 | 2 个解题者

加载更多