Skip to main content

Questions tagged [algorithm]

For challenges related to creating or implementing an algorithm.

-4 votes
3 answers
255 views

Motto of the day (MOTD) or Today's Motto is a algorithm to generate a unique & dynamic motto for every day. Input of the date to calculate motto for could be in any reasonable format. The program ...
QOO-OOKALAN's user avatar
-5 votes
1 answer
235 views

The daily motto is a project by me, allowing unique and dynamic motto every day. Here, you’ll attempt to rewrite my code, making it code-golf style. The motto uses a specific algorithm, determining ...
user avatar
1 vote
2 answers
333 views

I am looking to create a brainfuck program that can print the text "Hello, World" when executed--but not just that (it's too easy), it should also print "dlroW ,olleH" when the ...
Jore's user avatar
  • 137
14 votes
4 answers
1k views

The arrangement algorithm I think I've determined the algorithm that Google Calendar uses to visually arrange day-long and longer events at the top of the "Week" view (you may have an ...
Nicola Sap's user avatar
  • 3,823
15 votes
10 answers
3k views

The Venetian election system was... complicated. The Great Council came together and put in an urn the ballots of all the councilors who were older than 30. The youngest councilor went to St Mark's ...
KeizerHarm's user avatar
  • 1,373
27 votes
52 answers
4k views

Description Given an unsorted array of integers, find the smallest positive integer that does not appear in the array. Your task is to write the shortest code possible to solve this problem. Input A ...
aitzazisstuffed's user avatar
12 votes
10 answers
1k views

Introduction Our goal is to efficiently find the maximum of a large amount of (redundant) data. We define the outer product of vectors \$A\$ and \$B\$ as a matrix containing the products of all ...
Sebastian's user avatar
  • 221
7 votes
2 answers
525 views

Given a list of N lists, each containing M positive integers, and a separate list of M positive integers (target values), return a list of N scalars (integers with a value of 0 or more) that ...
drmosley's user avatar
  • 757
21 votes
25 answers
3k views

Introduction You're making a robot that can navigate a set of books of varying heights. It can climb books and jump off books, but if the distance is too big it will stop to prevent damage. To figure ...
Ginger's user avatar
  • 6,108
1 vote
0 answers
100 views

Based on this game. Description : Based on Wikipedia's description. The 24 Game is an arithmetical card game in which the objective is to find a way to manipulate four integers so that the end result ...
MSS2001's user avatar
  • 339
14 votes
9 answers
527 views

Challenge Your goal is to find the furthest point on a graph (from a provided start node). Your code doesn't need to handle cycles in the graph properly, but it might pose a fun challenge. For this ...
Hack5's user avatar
  • 341
1 vote
1 answer
501 views

In an attempt to “liberate” their fellow birds, a group of highly intelligent hens are attempting to compromise the zoo’s security system. To get access to the zoo’s mainframe, the hens first need to ...
VJZ's user avatar
  • 499
10 votes
1 answer
700 views

Convert NFA to DFA as quickly as possible. Input Your input will be an NFA. In order to be able to test your code, it needs to be able to handle an NFA in the following format. This is taken ...
user avatar
9 votes
1 answer
305 views

The Monkey has swung home to find his tree all in pieces. He likes order and scoops up all his 'tree-parts' and sets them out in 3 groups. The Monkey's ...
leopardxpreload's user avatar
2 votes
0 answers
257 views

After seeing some impossibly short solutions in this SE, I began to wonder what code someone could come up with to build a pseudo-random number generator. Now given that I am new to programming, I ...
user91975's user avatar

15 30 50 per page