This file contains 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
Sorted Bluetooth's MAC Addresses | |
[ | |
"00:06:66:7D:B9:A9", | |
"00:06:66:7D:B9:E2", | |
"00:06:66:7D:B9:E9", | |
"00:06:66:7D:BD:C5", | |
"00:06:66:7D:C1:16" | |
] | |
This file contains 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
// How to run | |
// cd <root which has pom.xml> | |
// scala PomToSbt.scala | |
// Then, you have output | |
object PomToSbt extends App{ | |
// (from: https://stackoverflow.com/a/15430347/2885946) | |
import scala.xml._ |
This file contains 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
[elvm]$ make -k scala | |
Skip building js due to lack of nodejs | |
Skip building asmjs due to lack of nodejs | |
Skip building cl due to lack of sbcl | |
sed: illegal option -- - | |
usage: sed script [-Ealn] [-i extension] [file ...] | |
sed [-Ealn] [-i extension] [-e script] ... [-f script_file] ... [file ...] | |
Skip building cs due to lack of | |
Skip building i due to lack of ick | |
Skip building forth due to lack of gforth |
This file contains 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
[elvm]$ make test-hs | |
Skip building js due to lack of nodejs | |
Skip building asmjs due to lack of nodejs | |
Skip building cl due to lack of sbcl | |
sed: illegal option -- - | |
usage: sed script [-Ealn] [-i extension] [file ...] | |
sed [-Ealn] [-i extension] [-e script] ... [-f script_file] ... [file ...] | |
Skip building cs due to lack of | |
Skip building i due to lack of ick | |
Skip building forth due to lack of gforth |
This file contains 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
s = <<EOS | |
{-# LANGUAGE FlexibleContexts #-} | |
{-# LANGUAGE AllowAmbiguousTypes #-} | |
{-# LANGUAGE MultiParamTypeClasses #-} | |
{-# LANGUAGE ScopedTypeVariables #-} | |
{-# LANGUAGE FlexibleInstances #-} | |
{-# LANGUAGE TypeApplications #-} | |
{-# LANGUAGE TypeFamilies #-} | |
{-# LANGUAGE NamedFieldPuns #-} |
This file contains 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 Data.Array.IO | |
import Data.IORef | |
import Data.Char | |
import Data.Bits | |
import System.Exit | |
import Control.Exception | |
main :: IO () | |
main = do | |
aRef <- newIORef 0 :: IO (IORef Int) |
サマーウォーズのアレです。
This file contains 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
# (from: http://melborne.github.io/2013/08/30/monkey-patching-for-prudent-rubyists/) | |
class Array | |
alias :get_at :[] | |
private :get_at | |
alias :set_at :[]= | |
private :set_at | |
def in_bound?(idx) | |
0 <= idx && idx < self.size |
OlderNewer