instruction_seed stringlengths 29 40.5k | source stringclasses 6
values |
|---|---|
Your objective is to engage in a multi-step analytical process to determine the total number of distinct ordered solutions to the equation a+b+c = x+y+z, constrained by the parameters 0 <= a,b,c,x,y,z < n, where n is an upper limit provided as input.
To elucidate, begin by deriving solutions for a range of values fro... | evolcodegolf |
Draw inspiration from the following excerpt from the Commodore 64 User's Manual, which outlines a simplistic graphics routine:
10 PRINT "{CLR/HOME}"
20 POKE 53280,7 : POKE 53281,13
30 X = 1 : Y = 1
40 DX = 1 : DY = 1
50 POKE 1024 + X + 40 * Y, 81
60 FOR T = 1 TO 10 : NEXT
70 POKE 1024 + X + 40 * Y, 32
80 X = X + DX
90... | evolcodegolf |
When creating a character for the tabletop role-playing game Dungeons & Dragons, one alternative to the traditional method of randomly generating ability scores is to utilize a structured point allocation system commonly referred to as point buy. In this system, the cost associated with higher ability scores escalates ... | evolcodegolf |
In alignment with the unconventional theme of peculiar culinary devices, let us delve into an exploration of the operational intricacies of my multifunctional microwave oven.
**Introduction**
This particular microwave is equipped with a user interface keypad structured as follows:
```
30 > 15
1 2 3
4 ... | evolcodegolf |
Your task is to design a program that is capable of printing its own source code without any modifications. You might wonder, "Why add another iteration to a well-trodden challenge?" However, this variant is intended to present a significantly heightened level of difficulty. Your quine must be "mutation-hardened," impl... | evolcodegolf |
Create an animated ASCII-art polygonal loading symbol on the screen, given three positive integers as input: \$n\$, \$l\$, and \$d\$.
Intro
The input \$n\$ (which must be one of the values \$3\$, \$4\$, \$6\$, or \$8\$) represents the number of sides of the polygon:
* * *
... | evolcodegolf |
Background
In the captivating game of Nim, participants engage in alternating turns to strategically remove "stones" from designated "piles": during each turn, a player is required to take away a minimum of one stone and a maximum of all stones from a solitary pile. The objective within Nim is to seize the last stone... | evolcodegolf |
Your task for today is to engage in an intriguing palindrome challenge! You will be required to analyze a given string and meticulously ascertain the minimum number of letters that need to be inserted to transform it into a palindrome. This process involves multiple steps of reasoning and consideration.
For instance,... | evolcodegolf |
Transform this inquiry into a more intricate exploration of the simplification process for an ijk string, specifically when applied to the dihedral group of order 8, along with custom labels reflecting the group's properties.
Challenge
Given a string composed solely of the characters r and s, interpret it as a prod... | evolcodegolf |
Explore the fascinating intersection of linguistics and mathematics by developing a framework that applies the concept of "Fourier Transform" to analyze the frequency of letters in textual strings.
### Introduction
If you've ever delved into signal processing, you might be familiar with the Fourier Transform, which d... | evolcodegolf |
The following represents a challenge that combines elements of coding prowess with mathematical uncertainty, specifically targeting the creation of concise code snippets. Your task is to craft the briefest code possible that embodies an unresolved question regarding its termination status. An illustrative example is th... | evolcodegolf |
Determine the outcome of a sequential two-player game of War by analyzing each player's chosen moves over a series of turns. This game, reminiscent of "Rock-Paper-Scissors," features three possible actions: Reload, Guard, and Fire, with specific rules dictating their interactions. Each player begins with zero ammo, can... | evolcodegolf |
In the context of examining a matrix A, we define it as being "sorted" if all its rows are arranged in ascending order from left to right, as well as its columns from top to bottom. For example, the matrix below meets the sorted criteria:
[ 1 2 3 4 5 ]
[ 2 2 3 4 5 ]
[ 3 3 3 4 5 ]
[ 4 4 4 4 5 ]
[ 5 5 5 5 5 ]
Conversel... | evolcodegolf |
Imagine a \$p \times q\$ grid filled with \$0\$'s and \$1\$'s, where each \$1\$ represents a "bubble." Instead of applying gravity, you will simulate an "explosion" effect that causes all \$1\$'s to spread outwards in all four cardinal directions until they hit a \$0\$ or the edge of the grid. Each \$1\$ will create a ... | evolcodegolf |
Given an integer n that is greater than or equal to 1, construct and display a two-dimensional grid representation of a percent sign with a specified width of n. The steps for creating this matrix are outlined as follows:
1. Generate an n by n matrix (or a list of lists) that is initially populated with zeroes.
2. Pla... | evolcodegolf |
In an intriguing juxtaposition of alphanumeric characters, consider the following scenario: Given a collection that may include both letters and integers (e.g., ['a', 2, 3, 'b']), increment each letter's position in the English alphabet by one (where 'z' cycles back to 'a'), while simultaneously decrementing each numer... | evolcodegolf |
The casino utilizes a specific deck of cards, represented as follows, where * denotes any of the suits D, S, C, or H.
_________ _________ _________ _________ _________
| | | | | | | | | |
| | | | | * | | * * | | * * |
| ... | evolcodegolf |
Formulate a solution inspired by this challenging puzzle that involves complex reasoning.
Challenge
You are presented with a 2D rectangular grid wherein each cell is categorized as either an empty space or a wall. Your task is to ascertain a viable path (or one of the possible paths) from the top left cell to the b... | evolcodegolf |
Background
Most individuals engaging with this subject matter are likely familiar with various integer base systems, including decimal, binary, hexadecimal, and octal. For instance, in the hexadecimal system, a representation such as \$abc.de_{16}\$ can be expressed as
$$a\times16^2 + b\times16^1 + c\times16^0 + d\... | evolcodegolf |
The KV file format utilized by Valve can be expressed in a pseudo-EBNF structure as follows:
<pair> ::= <text> <value>
<value> ::= <text> | <block>
<text> ::= "\"" <char>* "\""
<block> ::= "{" <pair>* "}"
Parsing initiates at the <pair> state. While whitespace can be interspersed freely throughout the input, it is ma... | evolcodegolf |
Given a sorted array of unique positive integers \$A\$ \$(A_0<A_1<\cdots<A_{n-1})\$, and an integer \$t\$, where \$A_0\le t\le A_{n-1}\$, your task is to output the index \$i\$ corresponding to the following conditions:
1. If \$t\$ is an element of \$A\$, find \$i\$ such that \$A_i=t\$.
2. If \$t\$ is not in \$A\$, de... | evolcodegolf |
In this intellectual duel, law enforcers must create a unique game engine, establishing a new game programming language with strict limitations. This language must focus on interactive storytelling, allowing for input and output related solely to narrative progression without external influences. The challenge is twofo... | evolcodegolf |
Envision a scenario set in the year 2050, where societal advancements have prompted a radical transformation in numerical representation. People are advocating for a system that minimizes memorization and facilitates rapid notation. In this innovative approach, each digit corresponds to its respective place value (ones... | evolcodegolf |
Transforming textual input into DNA sequences presents an intriguing challenge.
Task
Convert the given text into a DNA output, adhering to specified constraints.
Algorithm
1. Convert the input text into its corresponding ASCII code points (e.g., codegolf -> [99, 111, 100, 101, 103, 111, 108, 102])
2. Concatena... | evolcodegolf |
Your task: write a program/function that, when provided with a string containing solely ASCII characters, outputs/returns the string in reverse-ish format while also counting the total number of unique characters regardless of their case sensitivity.
Example:
1) Input
Hello, World!
2) Number unique character... | evolcodegolf |
Background
The network discovery utility Nmap is designed to accept a comprehensive list of TCP/UDP port numbers as input, executing a thorough security audit against the specified ports. Users can conveniently list selected port numbers on the command line in a string format, where individual port numbers are separa... | evolcodegolf |
A positive integer M is L-unique if its decimal representation contains at least L different digits. For instance, the number 12345 is 4-unique because it has four different digits (1, 2, 3, 4, 5) while 1123 is only 3-unique. Your task is to identify the smallest L-unique number greater than the given input. For exampl... | evolcodegolf |
You are developing a digital wallet application that optimally allocates funds for various transactions while ensuring the user maintains a balanced budget. Create a program that takes an input of total expenses for the week (e.g., $250.75) and suggests the best combination of categories (like groceries, entertainment,... | evolcodegolf |
GPA Calculator
(GPA = Grade Point Average)
You are a stressed-out college student during finals week. Instead of studying for your exams coming up, you decide it is best to determine what GPA you will have at the end of the semester. This way you have data to back up your decision of staying up all night to get tha... | evolcodegolf |
Characters
Let’s denote these Unicode characters representing English IPA consonants as follows:
bdfhjklmnprstvwzðŋɡʃʒθ
Similarly, let’s classify these Unicode characters as English IPA vowels:
aeiouæɑɔəɛɜɪʊʌː
(Note: Although ː is merely a long vowel mark, for the sake of this exercise, treat it as a vowel.... | evolcodegolf |
Wikipedia: Zeno's Dichotomy Paradox
An infinite number of mathematicians walk into a bar. The first one orders a beer. The second one orders half a beer. The third one orders a fourth of a beer. The bartender stops them, pours two beers and says, "You're all a bunch of idiots."
Reddit
Print the following series for a... | evolcodegolf |
There exists a bijection between the sets of natural and rational numbers that operates in a manner resembling the following:
You construct a 1-indexed two-dimensional matrix.
Within each cell of this matrix positioned at (x, y), insert the value x / y.
Commence at the coordinate (1,1) and progress through the cells u... | evolcodegolf |
What general tips do you have for golfing in 2-dimensional programming languages that take into account both code efficiency and maintainability? I'm looking for suggestions that can be applied to code-golf problems and are specific to 2D programming languages, but not tailored to any one language (Responses like "remo... | evolcodegolf |
Definition
There exists an infinite sequence composed of concatenated natural numbers (positive integers, commencing from 1):
1234567891011121314151617181920212223...
Challenge
Construct a program in any programming language that accepts a position number as input, and subsequently outputs the digit found at th... | evolcodegolf |
The input comprises i rows, each detailing information about neighboring entities. Each ith row is constituted of four values, signifying the neighbor located in the North, East, South, and West directions, respectively. Therefore, every value indicates a neighboring entity corresponding to the specified direction for ... | evolcodegolf |
In the intricate landscape of the United States Senate, which comprises precisely one hundred members, it is crucial to recognize that achieving legislative passage necessitates a minimum of fifty-one votes, assuming that no obstructionist tactics such as filibusters are employed and that the Vice President abstains fr... | evolcodegolf |
Your objective is to process a specified input string, for instance:
a,b,4,5
and produce an output string, which in this case would be aaaabbbbb. Here, a,b,4,5 signifies that the lowercase character "a" should be repeated 4 times, succeeded by the lowercase character "b" repeated 5 times, culminating in a total charact... | evolcodegolf |
The Vigenère cipher is a substitution cipher wherein the encryption process of each letter in the plaintext is contingent upon a distinct character from a keyword. This characteristic effectively obfuscates straightforward frequency analysis techniques that could otherwise facilitate the deduction of the appropriate su... | evolcodegolf |
On the spooky occasion of Halloween, our protagonist Jimmy (/o\) finds himself venturing into an enigmatic neighborhood to partake in the ritual of trick-or-treating (prompting him to contemplate his adventurous choices). Suddenly, he is pursued by sinister ghosts. Will Jimmy manage to elude his spectral pursuers?
Cha... | evolcodegolf |
I have the code below working, but there must be a more efficient approach to achieve the same results while also ensuring that the data is normalized for each column individually to prevent any scaling issues.
file <- "http://s3.amazonaws.com/assets.datacamp.com/production/course_1127/datasets/tmp_file.csv"
x <- read... | evolcodegolf |
Given an ASCII-art shape constructed from the characters /\|_, your task is to determine the total number of distinct sides it possesses. A side is characterized as a continuous, straight line formed by one of these specified characters. For instance:
\
\
\
/
/
|
|
|
|
_____
represents valid sides. As an illus... | evolcodegolf |
In the process of constructing a brick road adjacent to my existing brick wall, I seek your assistance!
\ \__\ \__\ \__\ \__\ \__\ \__\ \__\ \__\ \__\ \__\ \__\ \
\__\ \__\ \__\ \__\ \__\ \__\ \__\ \__\ \__\ \__\ \__\ \__
__\ \__\ \__\ \__\ \__\ \__\ \__\ \__\ \__\ \__\ \__\ \__... | evolcodegolf |
This presents yet another intricate challenge focused on Fibonacci sequences. The objective is to efficiently compute the 20,000,000th Fibonacci number in the shortest time possible. The resulting decimal output is expected to be approximately 4 MiB in size, beginning with:
28543982899108793710435526490684533031144309... | evolcodegolf |
This code golf challenge revolves around creating a rocket liftoff sequence that incorporates a countdown and must additionally print a "Countdown complete!" message immediately after the liftoff announcement.
Your output (STDOUT) should be equal to this:
Liftoff in T-10
Liftoff in T-9
Liftoff in T-8
Liftoff in T-7
Li... | evolcodegolf |
The challenge you are tasked with is straightforward yet intriguing:
Develop a function or program that accepts an input x, which when it is part of the lower case alphabet, results in the output being the corresponding lower case letter; if x belongs to the upper case alphabet, the function should return the equivalen... | evolcodegolf |
As one of the contributors to the Gimli project, I've collaborated on a concise 2-tweet (280 characters) iteration in C, but I am curious to determine the absolute minimum size achievable. Gimli (referenced paper and website) represents a high-speed, highly secure cryptographic permutation design set for presentation a... | evolcodegolf |
Situation:
A turtle embarks on a journey starting from the origin point (0, 0) on a two-dimensional Cartesian coordinate system.
We possess a non-empty, zero-indexed list entitled "moves" that comprises a series of integers.
Each integer signifies the distance traversed in a specific cardinal direction: the initial ... | evolcodegolf |
Engage in an analysis of regular expressions, particularly the formal variations discussed in automata theory, as recognized by sources like Wikipedia. Our exploration includes four fundamental operations, arranged hierarchically according to their precedence:
1. Parenthesis. (a)
The content enclosed within the pa... | evolcodegolf |
An integer is deemed "Boring" if it contains a digit or a sequence of digits that repeats continuously—where the term "continuously" refers to the uninterrupted succession of the same character—at least five times. For instance, while 11111 qualifies as Boring, 12345 does not.
Instructions:
1. Accept an integer as in... | evolcodegolf |
Task
Develop a program/function that, when provided with a positive integer \$m\$, divides the integers from \$1\$ to \$m\$ into three distinct groups, ensuring that for any integers \$x, y, z\$ where \$x^3 + y^3 = z^3\$ cannot all belong to the same group. For instance, if \$1, 2\$ are in the first group, then \$3\$... | evolcodegolf |
Story
Imagine a whimsical library filled with countless books, each uniquely shaped and sized. In this library, you decide to create a fantastical stack of books, but you want to ensure that the top book is a certain distance away from the floor, measured in "book lengths." Your task is to determine how many addition... | evolcodegolf |
Formulate a program that, given a string S as input, evaluates whether every character within S adheres to a Lexical Sequence: specifically, their ASCII values must be arranged in strictly ascending or descending order. The program should yield a truthy value in scenarios where the characters conform to this criterion,... | evolcodegolf |
I am a novice in the competitive field of code golf, and I aim to devise a structured ladder of integers utilizing the minimum quantity of distinct characters in the C++ programming language. For instance, if we are presented with the integer 4, the desired output would be structured as follows:
1
1 2
1 2 3
1 2... | evolcodegolf |
**Background**
Consider a structured round-robin tournament where each participant engages in a single match against every other participant. Each contest yields a definitive winner and a corresponding loser, eliminating the possibility of ties. A participant A is designated as a king of the tournament if, for every ... | evolcodegolf |
Given two distinct strings composed exclusively of the binary digits 0 and 1, determine the probability that the first string emerges earlier as a consecutive substring within an infinitely generated and random stream of 0s and 1s. It is pertinent to note that the assumption holds true that neither string acts as a suf... | evolcodegolf |
A stem and leaf plot serves as a method for organizing a collection of numerical values into defined groups, specifically categorized based on all digits except for the final one. To illustrate this concept, consider the following dataset:
0, 2, 12, 13, 13, 15, 16, 20, 29, 43, 49, 101
From this data, we can construct... | evolcodegolf |
In the realm of spreadsheet software, columns are designated with alphabetical labels starting from A, B, C, and progressing through to X, Y, Z. Following this initial sequence, the labeling continues with combinations such as AA, AB, AC, and subsequently advances to AX, AY, AZ, BA, and continues indefinitely. Your ass... | evolcodegolf |
Design a polyglot program that serves as a conditional quine for multiple languages, meaning that its output is dependent on the runtime environment, but each language must output its own valid source code when executed. The challenge lies in creating a structure where the polyglot can determine the executing language ... | evolcodegolf |
Background:
Here's a moderately intricate challenge. Your task is to determine whether all arrays contained within a provided array exhibit identical lengths. Additionally, consider that the function must handle arrays that may contain nested arrays of varying depths.
Input:
Your input should consist of exactly on... | evolcodegolf |
Envision a rudimentary programming language characterized by just two syntactical elements: parentheses () that delineate block scope, and identifiers composed solely of one or more lowercase ASCII alphabetic characters. This language eschews the inclusion of keywords, placing emphasis instead on identifier management.... | evolcodegolf |
The mathematical constant known as Euler's number, represented by the symbol \$e\$, raised to the power of a specific variable \$x\$, can be effectively estimated utilizing the Maclaurin Series expansion as follows:
$$e^x=\sum_{k=0}^{\infty}{\frac{x^k}{k!}}=1+x+\frac{x^2}{2!}+\frac{x^3}{3!}+\frac{x^4}{4!}+\dots$$
By su... | evolcodegolf |
Introduction
In moments of tedium, when the flow of fresh inquiries on PPCG dwindles, I invite you to unearth a random question from PPCG's extensive archives.
Challenge
Provided with a user's PPCG ID as input (for instance, my ID is 30525), generate the URL of a randomly selected PPCG question that adheres to th... | evolcodegolf |
In the programming realm of ><>, an esoteric two-dimensional language, the instruction pointer (IP) navigates through a codebox in a toroidal fashion, seamlessly wrapping around at the boundaries. This language utilizes four fundamental movement commands—namely <, >, ^, and v—which instruct the IP to adjust its traject... | evolcodegolf |
Introduction:
In an age dominated by digital communication, I maintain my preference for reading a traditional physical newspaper during my morning breakfast ritual. While I don't particularly enjoy Sudoku puzzles, I do engage with those classified as Light-complexity, which are notably simple. My approach is to solve ... | evolcodegolf |
Given an alphabet and a string, your task is to meticulously implement the Lempel–Ziv–Welch compression algorithm for the provided string, ensuring not only accuracy but also efficiency in your implementation. Your solution can manifest as either a function with two parameters and a return value or as a full program th... | evolcodegolf |
In numerous intricate image-processing scenarios, the post typically houses multiple images that necessitate saving to a designated file, enabling efficient problem-solving. This process can become an exasperating manual chore, and it is imperative that we programmers are spared from such mundane tasks. Your objective ... | evolcodegolf |
What particular strategies do you recommend for engaging in coding competitions focused on Haxe? I'm seeking actionable insights that can be effectively utilized in code-golf challenges, especially those tailored to the idiosyncrasies of Haxe (e.g., merely suggesting "remove comments" lacks depth). Please provide one d... | evolcodegolf |
The enigma surrounding the perceived size of the moon
It is widely recognized that the moon appears to fluctuate in size. When one is enamored and fortunate, the moon can seem almost double its typical dimensions compared to more mundane situations. Various individuals attribute this optical phenomenon to atmospheric... | evolcodegolf |
The alphabet mat that my children play on resembles the following configuration:
After enduring months of disorderly tile arrangements, I finally organized the tiles based on their background colors. Each letter corresponds to a specific color, resulting in the following layout:
AABBCDDDE
ABBCCCDEE
ABCCCCDDE
AACCCDDEE... | evolcodegolf |
Goal
Morse code is often represented as sound. Given a stream of bits that indicate whether sound is on or off, your task is to translate this stream into letters, numbers, and spaces, while adhering to a limit on the total number of characters in the final output.
Specifics
The bit stream is analyzed based on th... | evolcodegolf |
When I was a child, my father and I devised a game centered around deriving points from license plates based on a set of rules that, while seemingly straightforward, require careful consideration of sequences and character repetitions. The scoring mechanism awards points as follows: a repeated character or digit result... | evolcodegolf |
Given two positive integers A and B, your task is to identify the position p that minimizes the total count of prime factors (including multiplicities) of the resultant integer formed by inserting B into A at position p. This involves not only determining the possible insertion points but also analyzing the prime facto... | evolcodegolf |
Consider this particular challenge that I seem to have misplaced within the realm of my studies in Discrete Mathematics, a topic I engaged with approximately 5-6 months ago and have since struggled to fully retain.
Given a specific path of vertices that delineates a cycle within a graph, your task is to derive a more... | evolcodegolf |
A perfect shuffle is a shuffling method that involves dividing a deck of cards into equal-sized halves and interleaving them in a specific way. In a perfect shuffle, the top card of one half is placed first, followed by the top card of the other half, and this process continues until the entire deck is reassembled. For... | evolcodegolf |
Construct a 'branch' representation for a given binary number, ensuring that the tree structure exhibits a specified depth of 2. This entails producing offspring representations, extending the binary string by up to 2 additional digits in length. For instance, when the input is 0, the output must conform precisely to t... | evolcodegolf |
Problem Description
Given:
a function \$f(a, b, c, d, e) = \frac{a \times b}c + \frac de\$
an array \$x = [x_1, x_2, x_3, x_4, ..., x_n]\$ of non-distinct integers
a target value \$k\$
What is the most efficient way, in terms of worst-case \$n\$, to find 5 distinct indices \$x_a, x_b, x_c, x_d, x_e\$ from \$x... | evolcodegolf |
You are tasked with modifying an input string by substituting every instance of the word "Lemon" with "Lemonade," ensuring that the letters "a," "d," and "e" required for this transformation are creatively borrowed from different parts of the same sentence. Your response should reflect a multi-step reasoning process to... | evolcodegolf |
Develop a sophisticated application that simulates a classic blackjack game adhering to the following specifications:
input "h" signifies requesting an additional card from the deck, while input "s" indicates that the player wishes to remain with their current hand.
Rules:
card values are delineated as follows:
2 thr... | evolcodegolf |
You are tasked with developing a program or function that takes a string representation of a floor pattern as input and subsequently computes and returns the area of the most efficient meta-tiling capable of reproducing the specified floor configuration. The floor layout is defined within the confines of a square grid,... | evolcodegolf |
A young feline exhibits characteristics akin to those of an adult cat; however, a few notable distinctions arise, including varying levels of adorability, intellectual capacity, and physical dimensions. In addition, one can observe a divergence in command syntax between the two: the command utilized for the kitten diff... | evolcodegolf |
Devise a multifaceted program that replicates its functionality both in a forward direction and in reverse, utilizing distinct programming languages that are not merely variations of the same language family.
Challenge
This sophisticated program must possess the capability to accept any form of input while providing ... | evolcodegolf |
Introduction
In this intellectual exercise, we will engage with a specific and intricate ordering of the positive integers, defined as follows:
3, 5, 7, 9, 11, ...
2*3, 2*5, 2*7, 2*9, 2*11, ...
4*3, 4*5, 4*7, 4*9, 4*11, ...
8*3, 8*5, 8*7, 8*9, 8*11, ...
16*3, 16*5, 16*7, 16*9, ... | evolcodegolf |
Background
I encountered a highly intriguing Venn Diagram on the online encyclopedia Wikipedia: https://simple.wikipedia.org/wiki/Alphabet#/media/File:Venn_diagram_gr_la_ru.svg
This diagram delineates the physical representations of letters across the distinct alphabets, specifically highlighting the commonalities ... | evolcodegolf |
Exploring the intricacies of the Sierpinski triangle can yield a multitude of fascinating opportunities beyond its basic rendering. By adopting a focused perspective, we can reinterpret the upside-down triangles as nodes within a complex fractal graph framework. Let's embark on a detailed navigation of this graph, taki... | evolcodegolf |
The Challenge
Develop a function that processes a string representing a combination of bills and ends with a specific item index, generating the minimal number of bills needed to make a purchase or return remaining funds as a formatted string. The following items are available for purchase (0-indexed):
[2.50, 3.00,... | evolcodegolf |
Can you explore the complexity of arranging dominoes within a given structure?
Challenge
Consider a rectangular grid characterized by a specified width \$w\$ and height \$h\$, which is populated with 1s and 0s. You have the ability to position a domino on this grid only in instances where both adjacent cells contain t... | evolcodegolf |
Task
Design a program that receives a positive integer as input. The program will iterate through all integers starting from 0, concatenating each number to a String, and will halt once the total length of the String equals or exceeds the input value. A "compressed integer" is defined as the largest integer that can ... | evolcodegolf |
Challenge:
Inputs:
A string composed exclusively of printable ASCII characters (excluding spaces, tabs, and new-lines)
A boolean †
Output:
The components of the string are categorized into four distinct groups:
Lowercase letters
Uppercase letters
Digits
Other
Based on the boolean, we either return the highest occur... | evolcodegolf |
Formulate a response that identifies the longest contiguous sublist from a given list of positive integers, ensuring that the resultant sublist accommodates at most one pair of identical items. In instances where multiple sublists share the same maximum length, you may select any of these solutions to present. As this ... | evolcodegolf |
At times, individuals encounter significant frustration within the StackExchange ecosystem, particularly on StackOverflow.
Your objective is to engineer a bookmarklet that triggers a dramatic visual effect, such as an explosion, implosion, or some form of destruction on the StackOverflow webpage. This will serve as a ... | evolcodegolf |
The recent question about Wang tiles has led me to consider that creating Penrose tilings might serve as an intriguing popularity contest, particularly emphasizing innovative artistic interpretations of the tiles' arrangements.
Background
Wang tiles are tiles that can tile the plane, but only aperiodically (see Fill... | evolcodegolf |
Many individuals are likely familiar with the ASCII character set, correct? I trust that's the case. For as long as I can remember, I have relied on my go-to ASCII table reference website whenever I've required one. In this task, we will engage in some intriguing source code manipulation utilizing the various elements ... | evolcodegolf |
A captivating illusion relies on the fundamental principles of binary representation. The specific dynamics of this illusion unfold as follows:
An audience participant selects a natural integer within the inclusive range of 1 to x, where x is predetermined by the performer.
The performer presents the participant with... | evolcodegolf |
The player is tasked with continuously guessing a number ranging from 1 to 10 until they successfully identify the correct number to win the game. Upon making an incorrect guess, they will be informed whether their guess is too low or too high. Moreover, the player must adhere to the rule that each output line must be ... | evolcodegolf |
In this engaging challenge, your objective is to deftly deconstruct and modify a specific piece of code crafted by the law enforcement, as delineated in their provided link. Your modification will be deemed successful if the following criteria are met:
1. Your altered code exhibits a maximum Levenshtein distance of 10... | evolcodegolf |
Robbers thread
Cops,
Select two distinct strings of code, one designated as public and the other as confidential. We will refer to them as P and S. Your task involves crafting a program that employs solely permutations of these strings.
For instance: if you select P=hello and S=world, permissible programs could i... | evolcodegolf |
Design a function that formats a given string in a pyramid style, positioning each segment of a word that begins with a consonant one level higher than the previous segment.
For example:
Input: Beautiful Creations and Code Development
Output: B C D
eaut reati e o
i... | evolcodegolf |
The problem at hand involves the following scenario:
Given a non-empty set of points in the Cartesian plane, your task is to determine the smallest possible circle that encompasses all provided points (Wikipedia link). This task becomes rather straightforward when the number of points is limited to three or fewer; for ... | evolcodegolf |
Devise a program or function that calculates the \$n^{\text{th}}\$ destination of a mythical creature known as the "quokka," which begins its journey at square \$1\$ on an infinite chessboard arranged in a clockwise square spiral. This quokka moves by first seeking the highest numbered square it can legally reach that ... | evolcodegolf |
Lean is a theorem prover and programming language, currently recognized as the Language of the Month! In the context of this programming environment, what specific and actionable tips do individuals have for golfing effectively in Lean? As always, responses should focus exclusively on Lean (for example, stating "Remove... | evolcodegolf |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.