Skip to content

Latest commit

 

History

History
788 lines (773 loc) · 77.9 KB

File metadata and controls

788 lines (773 loc) · 77.9 KB

Easy challenges (82/82)

# Name Description Solution Test
1 Fizz Buzz A simple game involving divisibility tests. ✅💾 ✅💾
3 Prime Palindrome Biggest prime palindrome < 1000. ✅💾 ✅💾
4 Sum of Primes Sum of first 1000 primes. ✅💾 ✅💾
8 Reverse words Reversing an input sequence of words. ✅💾 ✅💾
18 Multiples of a Number Multiples of a number greater than another number. ✅💾 ✅💾
19 Bit Positions Bits in position x,y are same or different. ✅💾 ✅💾
20 Lowercase Lowercase text ✅💾 ✅💾
21 Sum of Digits Sum of digits comprising a number ✅💾 ✅💾
22 Fibonacci Series Print out the nth fibonacci number ✅💾 ✅💾
23 Multiplication Tables Print out the grade school multiplication table upto 12*12 ✅💾 ✅💾
24 Sum of Integers from File Print the sum of integers read from a file. ✅💾 ✅💾
25 Odd Numbers Print the odd numbers from 1 to 99. ✅💾 ✅💾
26 File Size Print the file size in bytes. ✅💾 ✅💾
29 Unique Elements Extract unique list from a sorted list of numbers. ✅💾 ✅💾
30 Set Intersection Print the intersection of two sets of numbers. ✅💾 ✅💾
31 Rightmost Char Print the position of the rightmost occurrence of a char. ✅💾 ✅💾
39 Happy Numbers Determine if a number is a happy number or not ✅💾 ✅💾
40 Self Describing Numbers Determine if a number is a self-describing number or not ✅💾 ✅💾
62 N Mod M Determine the modulus (without the modulus operator). ✅💾 ✅💾
67 Hex to Decimal Convert a hex number to it's decimal equivalent. ✅💾 ✅💾
82 Armstrong Numbers Determine if a number is an armstrong number. ✅💾 ✅💾
83 Beautiful Strings Facebook Hacker Cup 2013 problem. ✅💾 ✅💾
87 Query Board Set and get values from a matrix using tiny DSL ✅💾 ✅💾
91 Simple Sorting Sort several numbers ✅💾 ✅💾
92 Penultimate Word Find the next-to-last word ✅💾 ✅💾
93 Capitalize Words Capitalize words in a sentence ✅💾 ✅💾
96 Swap Case Swap case in a string ✅💾 ✅💾
97 Find a Writer Find a famous writer in a string ✅💾 ✅💾
99 Calculate Distance Calculate a distance between two points ✅💾 ✅💾
100 Even Numbers Determine if a number is even or not ✅💾 ✅💾
102 JSON menu IDs Calculate IDs in JSON menu ✅💾 ✅💾
103 Lowest Unique Number Find the lowest unique number in a set ✅💾 ✅💾
104 Word to Digit Substitute words to digits ✅💾 ✅💾
106 Roman Numerals Convert a cardinal number to a Roman numeral ✅💾 ✅💾
107 Shortest Repetition Find the shortest repetition in a string ✅💾 ✅💾
111 Longest Word Get the longest word in a sentence ✅💾 ✅💾
112 Swap Elements Swap elements in a list ✅💾 ✅💾
113 Multiply Lists Multiply elements in 2 lists ✅💾 ✅💾
115 Mixed Content Separate words with digits ✅💾 ✅💾
116 Morse Code Decode Morse code ✅💾 ✅💾
122 Hidden Digits Try to look behind the scenes ✅💾 ✅💾
124 Road Trip Do not be left without petrol ✅💾 ✅💾
128 Compressed Sequence Write a program that compresses a sequence of numbers ✅💾 ✅💾
131 Split The Number Evaluate the number according to the pattern ✅💾 ✅💾
132 The Major Element Find the major element in a sequence ✅💾 ✅💾
136 Racing Chars Explore a race track avoiding crashes ✅💾 ✅💾
139 Working experience Retrieve an actual value ✅💾 ✅💾
140 Data Recovery Reconstruct a sentence using hints ✅💾 ✅💾
147 Lettercase Percentage Ratio Find the percentage ratio. ✅💾 ✅💾
149 Juggling With Zeros Convert a zero-based number into integer. ✅💾 ✅💾
152 Age distribution Print out where the person is. ✅💾 ✅💾
156 Roller Coaster Turn the text into RoLlErCoAsTeR case. ✅💾 ✅💾
160 Nice angles Convert angle values to sexagesimal format. ✅💾 ✅💾
163 Big Digits Print out magnified digits using pseudographics. ✅💾 ✅💾
166 Delta Time Find the time difference. ✅💾 ✅💾
167 Read More Limit the length of the text. ✅💾 ✅💾
173 Without Repetitions Delete characters that are consistently repeated. ✅💾 ✅💾
174 Slang Flavor Add some slang to the text. ✅💾 ✅💾
179 Matrix Rotation Rotate a 2D matrix 90 degrees clockwise. ✅💾 ✅💾
180 Knight Moves Find positions for the next move of the knight. ✅💾 ✅💾
183 Details Determine how many cells will be shifted detail. ✅💾 ✅💾
186 Max Range Sum Determine max sum at the range. ✅💾 ✅💾
189 Minimum Distance Find a point with the smallest sum of distances to every given point. ✅💾 ✅💾
192 Compare Points Given two (x, y) points A and B, determine which cardinal direction B is from A. ✅💾 ✅💾
196 Swap Numbers Swap numbers surrounding a word ✅💾 ✅💾
199 String mask Change case letters by mask ✅💾 ✅💾
202 Stepwise word Print the longest word in a stepwise manner ✅💾 ✅💾
203 Strings and arrows Print the number of arrows in a string ✅💾 ✅💾
205 Clean up the words Print the words separated by spaces ✅💾 ✅💾
208 Find the highest score Find the highest rate in the table ✅💾 ✅💾
211 Chardonnay or Cabernet Guess a wine name. ✅💾 ✅💾
214 Time to eat Sort timestamps in the right order. ✅💾 ✅💾
217 One zero, two zeros... Count zeros in a binary system. ✅💾 ✅💾
220 Trick or Treat Count all candies. ✅💾 ✅💾
222 Black card Find the winner. ✅💾 ✅💾
225 Testing Wanna try to be a tester? ✅💾 ✅💾
227 Real fake Check credit card numbers. ✅💾 ✅💾
230 Football Find countries that are football fans. ✅💾 ✅💾
232 Not so clever Simplicity is not always good. ✅💾 ✅💾
235 Simple or trump Check which card is higher. ✅💾 ✅💾
237 Panacea - truth or lie Check whether the virus was stopped by antivirus. ✅💾 ✅💾
240 Mersenne prime Find all Mersenne numbers smaller than n. ✅💾 ✅💾

Hard challenges (26/28)

# Name Description Solution Test
6 Longest Common Subsequence LCS between two strings. ✅💾 ✅💾
7 Prefix expressions Evaluating a prefix expression. ✅💾 ✅💾
14 String Permutations Print out all permutations of a string. ✅💾 ✅💾
28 String Searching Determine if substring match exists. ✅💾 ✅💾
36 Message Decoding Decode an encoded message ✅💾 ✅💾
38 String List Create a new string from constituent alphabets ✅💾 ✅💾
42 Ugly Numbers Count the number of expressions that can be created from a number 💾 💾
44 Following Integer Determine the next number in a sequence ✅💾 ✅💾
47 Palindromic Ranges Find out a range of palindromic numbers ✅💾 ✅💾
50 String Substitution Create a new string by replacing substrings within it ✅💾 ✅💾
51 Closest Pair Given a set of points in a two dimensional space, you will have to find the distance between the closest two points. ✅💾 ✅💾
52 Text Dollar Print out the text dollar amount of a given quantity ✅💾 ✅💾
56 Robot Movements Number of ways a robot can reach its destination ✅💾 ✅💾
57 Spiral Printing Print out a 2D array in spiral order ✅💾 ✅💾
59 Telephone Words Print out the words corresponding to a telephone number ✅💾 ✅💾
65 Word Search Find if a word exists in a grid ✅💾 ✅💾
72 Minimum Path Sum Calculate the minimum sum of a path through a matrix. ✅💾 ✅💾
79 Minesweeper Find the mines within a M*N matrix. ✅💾 ✅💾
105 Largest Sub-Matrix Determine the largest sub-matrix in a matrix ✅💾 ✅💾
108 Computer Terminal Print text to terminal with control sequences ✅💾 ✅💾
126 Play with DNA Write an algorithm that a finds DNA segment in a given DNA string 💾 💾
144 Digit statistics Find statistics in sequence ✅💾 ✅💾
155 ASCII Decryption Decrypt a message. ✅💾 ✅💾
157 The Labyrinth Find the shortest way to exit. ✅💾 ✅💾
162 Too unique Find and mark the biggest submatrices of unique elements. ✅💾 ✅💾
210 Brainf*ck Blow your mind ✅💾 ✅💾
213 Lakes, not cakes Count all lakes. ✅💾 ✅💾
216 Everything or nothing Check if a code is correct. ✅💾 ✅💾

Moderate challenges (81/81)

# Name Description Solution Test
2 Longest Lines Finding the 'N' longest lines within a file. ✅💾 ✅💾
5 Detecting Cycles Detecting loops within a sequence. ✅💾 ✅💾
9 Stack Implementation Implement a stack interface ✅💾 ✅💾
10 Mth to last element Determine the Mth to last element ✅💾 ✅💾
11 Lowest Common Ancestor Determine the lowest common ancestor within a tree ✅💾 ✅💾
12 First Non-Repeated Character Find the first non repeated character in a string. ✅💾 ✅💾
13 Remove Characters Delete specific characters from a string. ✅💾 ✅💾
15 Endianness Determine the endianness of a system. ✅💾 ✅💾
16 Number of Ones Determine the number of one bits in an integer. ✅💾 ✅💾
17 Sum of integers Determine the largest sum of contiguous integers in an array. ✅💾 ✅💾
27 Decimal To Binary Print the binary representation of a decimal number. ✅💾 ✅💾
32 Trailing String Determine if a string 'B' occurs at the end of string 'A' ✅💾 ✅💾
33 Double Squares FaceBook Hacker Cup 2011: Output the number of ways to write X as the sum of two squares ✅💾 ✅💾
34 Number Pairs Find pairs of numbers in a sorted array whose sum is X ✅💾 ✅💾
35 Email Validation Write a regular expression to validate an email address ✅💾 ✅💾
37 Pangrams Find the missing alphabets ✅💾 ✅💾
41 Array Absurdity Determine if an array contains a duplicated entry ✅💾 ✅💾
43 Jolly Jumpers Determine if a sequence of numbers is a Jolly Jumper ✅💾 ✅💾
45 Reverse and Add Continually add a number to its reverse to arrive at a palindrome ✅💾 ✅💾
46 Prime Numbers Print prime numbers less than N ✅💾 ✅💾
54 Cash Register Determine the amount of change to be returned ✅💾 ✅💾
63 Counting Primes Count the number of primes between two integers. ✅💾 ✅💾
66 Pascals Triangle Print out pascals triangle upto a certain depth. ✅💾 ✅💾
68 Valid parentheses Determine if string is a well-formed parentheses ✅💾 ✅💾
70 Overlapping Rectangles Determine if two rectangles overlap. ✅💾 ✅💾
71 Reverse Groups Reverse elements in a list k items at a time. ✅💾 ✅💾
73 Decode Numbers Count the number of ways to decode a string. ✅💾 ✅💾
74 Minimum Coins Find the minimum number of coins to arrive at a total. ✅💾 ✅💾
75 Flavius Josephus Eliminate every i'th item from a circular list. ✅💾 ✅💾
76 String Rotation Find if a string is the rotation of another string. ✅💾 ✅💾
78 Sudoku Determine if a grid layout is a valid sudoku solution. ✅💾 ✅💾
80 URI Comparison Determine if two URIs match ✅💾 ✅💾
81 Sum to Zero Count of ways in which the sum of four numbers is zero ✅💾 ✅💾
84 Balanced Smileys Facebook Hacker Cup 2013 problem. ✅💾 ✅💾
89 Pass Triangle Lead the way within the triangle ✅💾 ✅💾
94 Simple Calculator Create a simple calculator ✅💾 ✅💾
98 Point in Circle Define whether a point is in a circle ✅💾 ✅💾
101 Find a Square Do 4 points make a square? ✅💾 ✅💾
117 A Pile of Bricks Close a hole in a wall ✅💾 ✅💾
119 Chain Inspection Try to pass a chain ✅💾 ✅💾
121 Lost In Translation Try to become a native speaker ✅💾 ✅💾
125 Predict the Number Try to go beyond the limits ✅💾 ✅💾
130 Sequence Transformation Transform a binary sequence into a string ✅💾 ✅💾
133 City Blocks Flyover Chart the path of a helicopter from above to discover how many city blocks it flew over. ✅💾 ✅💾
135 Word chain Find the longest chain of words ✅💾 ✅💾
137 Seek for an Intruder Find the IP address of an intruder ✅💾 ✅💾
138 Car Race Determine the fastest car ✅💾 ✅💾
143 The Ministry of Truth Your task is to help the Big Brother ✅💾 ✅💾
146 Bats Challenge Count bats on the wire. ✅💾 ✅💾
148 Color Code Converter Determine and convert the color code ✅💾 ✅💾
150 Roman and Arabic Calculate aromatic numbers. ✅💾 ✅💾
153 Locks Calculate unlocked doors. ✅💾 ✅💾
158 Interrupted Bubble Sort Sort a list of elements. Partially. ✅💾 ✅💾
161 Game of Life Implement the classical cellular automaton game. ✅💾 ✅💾
165 Suggest Groups Help your friends to join groups. ✅💾 ✅💾
169 Filename Pattern Filter a list of filenames. ✅💾 ✅💾
170 Guess the Number Guess the number in log2(N) steps. ✅💾 ✅💾
172 Card number validation Check if bank card numbers are valid. ✅💾 ✅💾
177 Justify the Text Align the text to the specified width. ✅💾 ✅💾
178 Broken LCD Determine whether a given number can be displayed on the damaged LCD. ✅💾 ✅💾
181 Gronsfeld cipher Decipher the message enciphered with the Gronsfeld cipher. ✅💾 ✅💾
184 Burrows-Wheeler transform Complete file decompression by inverting BWT. ✅💾 ✅💾
187 Consecutive Primes Determine how many ways the numbers can be arranged such that every consecutive pair sums to a prime. ✅💾 ✅💾
190 Number Operations Determine if it is possible to produce the number 42 with five cards. ✅💾 ✅💾
193 Magic Numbers Print out a list of all the magic numbers in a provided range. ✅💾 ✅💾
194 Twenty Forty Eight Implement the 2048 game logic ✅💾 ✅💾
197 Column Names Convert integer to excel-style column name ✅💾 ✅💾
200 Sort matrix columns Sort matrix columns from lowest to highest numbers ✅💾 ✅💾
206 Lucky tickets Count the lucky tickets ✅💾 ✅💾
209 Black or white Find the smallest submatrix ✅💾 ✅💾
212 Robo and Robitta Count all nuts. ✅💾 ✅💾
215 Double trouble Calculate the number of correct variants for messages. ✅💾 ✅💾
218 Builders team. Count all squares on the map. ✅💾 ✅💾
221 Organizational Hierarchy Recreate the hierarchy tree. ✅💾 ✅💾
223 Alternative reality Count all alternative ways. ✅💾 ✅💾
226 Try to solve it How good decoder are you? ✅💾 ✅💾
228 To PI or not to PI Print a PI number. ✅💾 ✅💾
231 Meet Cocktail sort Learn more about cocktail sort algorithm. ✅💾 ✅💾
233 Meet Comb sort Learn more about the comb sort algorithm. ✅💾 ✅💾
236 Beat or bit Learn more about the Gray code algorithm. ✅💾 ✅💾
238 Code combinations Check whether you can make words from the given letters. ✅💾 ✅💾