Solved


letter yes yes & letter no no
Split a string into two strings, wherein the first string has all alphabetic letters and the second string has all the remaining...

11 months ago

Solved


Formatting currency numbers
Given a number, format it properly for textual display using the notation $xxx,xxx,xxx.xx. Assume that no more than two digits ...

12 months ago

Solved


Reverse the Words (not letters) of a String
*Description* Change the words of a string such that the words appear in reverse order. You may assume that the string is a n...

12 months ago

Solved


Pig Latin to English Translator
Pig latin is a faux-language based off of English. The rules are as follows (excerpted from the <http://en.wikipedia.org/wiki/Pi...

12 months ago

Solved


Find mistyped words in text (mixed-up letters)
Mistyped words are a regular occurrence in emails, texts, status updates, and the like. Many times, people send or post a second...

12 months ago

Solved


Convert a structure into a string
Convert the contents of each fields into a string. Example with an input structure s with 2 fields : s.age = '33' s....

12 months ago

Solved


Find Rotated Substring
Given a string s1, find if a rotated version of s1 is present in a second string s2. For example, rotated version of some strin...

12 months ago

Solved


Project Euler: Problem 2, Sum of even Fibonacci
Each new term in the Fibonacci sequence is generated by adding the previous two terms. By starting with 1 and 2, the first 10 te...

12 months ago

Solved


Return the Fibonacci Sequence
Write a code which returns the Fibonacci Sequence such that the largest value in the sequence is less than the input integer N. ...

12 months ago

Solved


Decimal Comparison
*Background* A utility of particular interest to Cody and other MATLAB ventures is comparing the equality of two numbers. In ...

12 months ago

Solved


Ordinal numbers
Given an integer n, return the corresponding ordinal number as a character string. For example, ord(1)='1st' ord(2)=...

12 months ago

Solved


Transposition as a CIPHER
This all about transcripting a text message. If the input string is: s1 = 'My name is Sourav Mondal', then the output is: s2 = '...

12 months ago

Solved


Minkowski distance

12 months ago

Solved


Calculate the Distance to Source of Lightning
Lightning discharge heats air rapidly with lightning channels reaching temperatures of up to 50,000 degrees Fahrenheit (which is...

1 year ago

Solved


Most Frequent Word - 01
Given a document file or a character array, find out the most frequent word in that document. In the case of multiple words -...

1 year ago

Solved


Where the Four Corners Am I?
The "Four Corners" region of the US is where Colorado, Utah, Arizona, and New Mexico all meet - the only place where four states...

1 year ago

Solved


Given two arrays, find the maximum overlap
Given two (integer) arrays s1 and s2, create a new array s3 which is as short as possible and contains both arrays. #1 s1 = [...

1 year ago

Solved


Word Counting and Indexing
You are given a list of strings, each being a list of words divided by spaces. Break the strings into words, then return a maste...

1 year ago

Solved


Remove all the words that end with "ain"
Given the string s1, return the string s2 with the target characters removed. For example, given s1 = 'the main event' your ...

1 year ago

Solved


Project Euler: Problem 6, Natural numbers, squares and sums.
The sum of the squares of the first ten natural numbers is, 1^2 + 2^2 + ... + 10^2 = 385 The square of the sum of the first ...

1 year ago

Solved


Integer sequence - 2 : Kolakoski sequence
Get the n-th term of Kolakoski Sequence.

1 year ago

Solved


Calculate area of sector
A=function(r,seta) r is radius of sector, seta is angle of sector, and A is its area. Area of sector A is defined as 0.5*(r^2...

1 year ago

Solved


Pizza!
Given a circular pizza with radius z and thickness a, return the pizza's volume. [ z is first input argument.] Non-scored bonus...

1 year ago

Solved


Right Triangle Side Lengths (Inspired by Project Euler Problem 39)
If p is the perimeter of a right angle triangle with integral length sides, { a, b, c }, there are exactly three solutions for p...

1 year ago

Solved


Find my daddy long leg (No 's')
Given the ratio of the two legs (longer / shorter), and the hypotenuse length, find the value of the bigger leg.

1 year ago

Solved


Height of a right-angled triangle
Given numbers a, b and c, find the height of the right angled triangle with sides a and b and hypotenuse c, for the base c. If a...

1 year ago

Solved


How many days?!?
Christmas is coming earlier and earlier each year. Thanks to rampant commercialism and Christmas Creep, "The Twelve Days of Chr...

1 year ago

Solved


You LOVES Matlab 41%
Given two strings, determine the percentage that one loves the other in the following way: YOU LOVES MATLAB there is 1 '...

1 year ago

Solved


Solve the Sudoku Row
*Description* A simple yet tedious task occurs near the end of most Sudoku-solving algorithms, computerized or manual. The ta...

1 year ago

Solved


Snow Accumulation and Structural Risks To Residential Properties
The density of snow depends on the amount of liquid water it contains: Dry Snow is about 50 kg/m^3 Wet Snow is about 200 kg/m^...

1 year ago

Load more