49 questions linked to/from Tips for golfing in Mathematica
4k views

Is this word Lexically Ordered?

Given an input string S, return truthy if all the letters in S are Lexically Ordered: their ASCII values need to be in either ascending or descending order. Return <...
6k views

The forbidden built-in

In the standard loopholes, the following is forbidden: Claiming that your answer is written in "MyOwnLanguage", where the command x means "read a sequence of ...
7k views

Flatten the Array!

In this challenge, your task is to create a program which takes in a nested array and returns a single-dimensional flattened array. For Example [10,20,[30,],50] ...
3k views

Increment an Array

Given a nonempty array of positive integers, "increment" it once as follows: If all the array elements are equal, append a 1 to the end of the array. For example: ...
2k views

Divisor skyline

For any positive integer k, let d(k) denote the number of divisors of k. For example, ...
2k views

String subtraction

Objective Create a function to reverse string concatenation Input Two strings (alphanumeric + spaces), where one should be subtracted for the other. You can assume that the string to be ...
3k views

Let's decrease the monotony

...but hey, no need to be strict. Given a non-empty array of strictly positive integers, determine if it is: Monotone strictly decreasing. This means that each entry is strictly less than the ...
7k views

Theoretically output Graham's number

Graham's number G is defined in this way: ...
8k views

The prime frog 🐸

The "prime frog" is a strange animal that jumps between integers, until it arrives on 3 or 19... Your program should accept an integer n as input and output the ...
4k views

How Many Rectangles in the Grid?

Well, although this challenge turned out to be a huge success, it also turned out to be very trivial to solve. Therefore, for those of looking for more of a challenge, I created a sequel to this ...
3k views

Hate/love conundrum

Challenge description In this challenge, we only consider love and hate as feelings. If we want to utter a feeling expression ...
2k views

Decompose binary into alternating subsequences

This was inspired by Problem 13 - Non-Repeating Binary of HP CodeWars' recent competition. Let's take a random decimal number, say 727429805944311 and look at ...
6k views

Is it a good 2048 board?

This is my first question here, so any suggestions in the comments would be appreciated! Thanks ;) Introduction One very common strategy for the 2048 game is never ever swiping down. This positions ...
Sum $\text{Square}^2$
Let $n=42$ (Input) Then divisors are : 1, 2, 3, 6, 7, 14, 21, 42 Squaring each divisor : 1, 4, 9, 36, 49, 196, 441, 1764 Taking sum (adding) : 2500 Since $50\times 50=2500$ therefore we return ...