Top "Puzzle" questions

DO NOT USE - prefer constructive questions, or use more descriptive tags.

Custom image mask in iOS

I have a issue with masking images. I do game "puzzle" and have to make custom images. I found and …

iphone ios calayer puzzle cashapelayer
Factorial in C without conditionals, loops and arithmetic operators

How can I find the factorial of a number (from 1 to 10) in C, without using: loop statements like for, while, …

c algorithm puzzle
Linear Time Voting Algorithm. I don't get it

As I was reading this (Find the most common entry in an array), the Boyer and Moore's Linear Time Voting …

algorithm language-agnostic puzzle
Question from Interview, Retrieve alphabetic order from dictionary

My girlfriend got this question in an interview, and I liked it so much I thought I'd share it... Write …

algorithm puzzle graph-theory topological-sort
How do I programmatically return the max of two integers without using any comparison operators and without using if, else, etc?

How do I programmatically return the maximum of two integers without using any comparison operators and without using if, else, …

c bit-manipulation max obfuscation puzzle
How to test randomness (case in point - Shuffling)

First off, this question is ripped out from this question. I did it because I think this part is bigger …

math theory random puzzle
puzzle: N persons sitting on round table. No of ways of handshakes without crossing any other handshakes

We have n persons sitting on a round table. Any person can do a handshake with any other person. In …

algorithm puzzle catalan
C puzzle: Make a fair coin from a biased coin

How can I determine the probability that a function would return 0 or 1 in the following case: Let the function_A …

c algorithm math puzzle probability
Single Number II from leetcode

The question about Single Number II from leetcode is: Given an array of integers, every element appears three times except …

java algorithm bit-manipulation puzzle
Designing a twenty questions algorithm

I am interested in writing a twenty questions algorithm similar to what akinator and, to a lesser extent, 20q.net …

algorithm artificial-intelligence puzzle