Also take a look at the directional coloration map
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| A Whirlwind Tour of Combinatorial Games in Haskell | |
| ================================================== | |
| Combinatorial games are an interesting class of games where two | |
| players take turns to make a move, changing the game from one position | |
| to another. In these games, both players have perfect information | |
| about the state of the game and there is no element of chance. In | |
| 'normal play', the winner is declared when the other player is unable | |
| to move. A lot of famous strategy games can be analysed as | |
| combinatorial games: chess, go, tic-tac-toe. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/sh | |
| # | |
| # Automatic configuration of a VPN on GCE debian-7-wheezy server. | |
| # Tested only on debian-7-wheezy. | |
| # | |
| # This work is licensed under the Creative Commons Attribution-ShareAlike 3.0 | |
| # Unported License: http://creativecommons.org/licenses/by-sa/3.0/ | |
| # | |
| # Thx to: https://github.com/sarfata/voodooprivacy/blob/master/voodoo-vpn.sh for the code/idea | |
| # |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #' Excel: PMT (should make result data frame, but need to change propertyAnalysis()) | |
| #' | |
| #' Returns the payment amount for a loan based on a constant interest rate and a constant payment schedule. | |
| #' The payment returned by PMT includes principal and interest but no taxes, | |
| #' reserve payments, or fees sometimes associated with loans. | |
| #' Outgoing payments are displayed by negative numbers and | |
| #' incoming payments by positive numbers. | |
| #' #http://support2.microsoft.com/kb/214005#appliesto | |
| #' @param rate Required. The interest rate per period. Needs to be defined as the same periods as nper. | |
| #' @param per Required. The period for which you want to find the interest and must be in the range 1 to nper. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # vim: set softtabstop=2 tabstop=2 shiftwidth=2 expandtab autoindent syntax=nix nocompatible : | |
| # Containers | |
| { config, pkgs, ... }: | |
| { containers.browser = | |
| let hostAddr = "192.168.100.10"; | |
| in | |
| { privateNetwork = true; | |
| hostAddress = hostAddr; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import Control.Concurrent.MVar | |
| type Channel a = (ReadPort a, WritePort a) | |
| type ReadPort a = MVar (Stream a) | |
| type WritePort a = MVar (Stream a) | |
| type Stream a = MVar (Item a) | |
| data Item a = MkItem a (Stream a) | |
| newChan :: IO (Channel a) | |
| newChan = do |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| *.ipynb | |
| *.png | |
| *.tar.gz | |
| .ipynb_checkpoints | |
| .ipython | |
| .jupyter | |
| .sentinel.* |
This document is licensed CC0.
These are some questions to give a sense of what you know about FP. This is more of a gauge of what you know, it's not necessarily expected that a single person will breeze through all questions. For each question, give your answer if you know it, say how long it took you, and say whether it was 'trivial', 'easy', 'medium', 'hard', or 'I don't know'. Give your answers in Haskell for the questions that involve code.
Please be honest, as the interviewer may do some spot checking with similar questions. It's not going to look good if you report a question as being 'trivial' but a similar question completely stumps you.
Here's a bit more guidance on how to use these labels:
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| {-#LANGUAGE BangPatterns #-} | |
| module Main (main) where | |
| import Data.Conduit as C | |
| import qualified Data.Conduit.Combinators as C | |
| import Pipes as P | |
| import qualified Pipes.Prelude as P | |
| import qualified Streaming.Prelude as Str |

