Problema


Compute a sequence with the whyphi sieve
A few problems on Cody involve sieving. For example, Cody Problem 45367 involves the famous Sieve of Eratosthenes. CP 50811uses ...

oltre 2 anni fa | 0 | 6 risolutori

Risolto


USC Fall 2012 ACM : Code Word Minimum Flipped Bits
This Challenge is to solve Question A of the <http://contest.usc.edu/index.php/Fall12/Home USC ACM Fall 2012 Contest>. Given ...

oltre 2 anni fa

Risolto


Easy Sequences 40: Quadratic Congruence
Quadratic Congruence is a modular equation of the form: . In this exercise you will be given a vector containing the coefficie...

oltre 2 anni fa

Risolto


Alternate Arrangement
Determine the ways of arranging 'm' men and 'w' women alternatively in a row of 's' seats. Assumptions : s<m and s<w

oltre 2 anni fa

Risolto


Draw the Greek letter 'α'
Given the dimensions of a matrix nRow and nCol where nCol > nRow, draw the Greek letter 'α' with 1's and 0's. You can consider t...

oltre 2 anni fa

Risolto


Opposite point of the earth, what is the antipodal of a point ?
Given two strings(lat and long) that represent the geographic coordinates of a point in the earth, you have to find out what is ...

oltre 2 anni fa

Problema


Alert a city about a spill
Problem statement Cody Problem 54750 involved determining the length of a stream affected by a spill. Any municipalities within...

oltre 2 anni fa | 2 | 6 risolutori

Problema


Find primes and integers that solve an equation
Write a function to find all primes and non-negative integers that solve the equation where is an integer. If there are no...

oltre 2 anni fa | 1 | 11 risolutori

Risolto


Find the triplet
Given an array x of size n > 3 and an integer N, return the indices of three elements in the array that sum up to the given inte...

oltre 2 anni fa

Risolto


Cos x
Retorne o cosseno de x, onde x está em radianos

oltre 2 anni fa

Risolto


Número de elementos do array
Retorne o número de elementos de um array

oltre 2 anni fa

Risolto


Valor absoluto de x
Dado uma entrada x, retornar o seu valor absoluto

oltre 2 anni fa

Risolto


Seno de x
Calcule o seno de x, onde x está em radianos

oltre 2 anni fa

Risolto


Eleve ao cubo!
dado uma entrada x, encontre o seu cubo

oltre 2 anni fa

Risolto


What is the current time in Darwin, Australia?
Traders need to track exchange calendars and trading hours in detail, and account for time zone differences and daylight savings...

oltre 2 anni fa

Risolto


Compute the area of a Q
A figure resembling a Q (as in “quadrature”) is constructed in the following way: A right triangle is drawn with the left vertex...

oltre 2 anni fa

Problema


List the smallest numbers with n distinct prime factors
The author of a book I am reading asked a mathematician what it feels like to be sixty. He wrote He replied, “Sixty, sandwiched...

oltre 2 anni fa | 1 | 7 risolutori

Problema


Classify numbers as abundant, deficient, or perfect
A number is perfect if the sum of its proper divisors (i.e., divisors excluding the number itself) is equal to itself. For examp...

oltre 2 anni fa | 0 | 10 risolutori

Risolto


Family Savings Analysis
Given the bank accounts of individuals defined by a list of tuples containing the last name, first name, and savings: accounts ...

oltre 2 anni fa

Problema


Determine whether a property description closes
The arrival of summer makes think back to the summers I spent working for my father’s engineering firm. For the first several s...

oltre 2 anni fa | 1 | 6 risolutori

Problema


Compute the area of a Q
A figure resembling a Q (as in “quadrature”) is constructed in the following way: A right triangle is drawn with the left vertex...

oltre 2 anni fa | 1 | 10 risolutori

Risolto


Determine the potential energy in a springrope which hangs over from a bridge
The task is to figure out the energy a person with mass has when hung on a rope over a bridge when given the length from the sus...

oltre 2 anni fa

Risolto


Area of right triangle
Given a hypotenuse and a leg , calculate the area of right triangle.

oltre 2 anni fa

Risolto


Hofstadter Female and Male sequences
The Hofstadter Female (F) and Male (M) sequences are defined as follows Write a function to compute for a given n. See http...

oltre 2 anni fa

Problema


Travel a path
In Cody Problem 60251, minnolina asks us to determine the end point given a string indicating unit movements forward, backward, ...

oltre 2 anni fa | 0 | 8 risolutori

Risolto


x

oltre 2 anni fa

Risolto


Instructions Following
Complete the function follow(s) which, for a given string (containing only the letters 'f', 'b', 'l', 'r'), calculates the final...

oltre 2 anni fa

Problema


Add non-triangular numbers
The nth triangular number is the sum of the first n positive integers. The sequence of triangular numbers starts 1, 3, 6, 10, 15...

oltre 2 anni fa | 1 | 16 risolutori

Problema


Compute the area of a lune
Write a function to compute the area of the shaded moon-shaped region in the figure below—that is, the area of a smaller circle ...

oltre 2 anni fa | 1 | 10 risolutori

Risolto


Spreadsheet Column Number
Spreadsheet uses an alphabetic naming system for columns, starting with 'A', 'B', 'C', etc. The column names continue like 'AB',...

oltre 2 anni fa

Carica altro