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
"-------------------------" | |
" パラメータ設定 " | |
"-------------------------" | |
"{{{ | |
"---------------------------------------- | |
" ヒント " | |
" @Undecide => 完全に動作するか未確定 | |
" @Wakegawa => わけがわからないよ(なぜかこれなら動作する…等) | |
" @Provisional => 仮設定 | 仮配置 |
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 Control.Applicative | |
main = putStrLn $ show divisorList | |
divisorList = a | |
where | |
max = 120 | |
a = {-filter (<=max) $ -}(*) <$> [1..] <*> [3,5..] |
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
loseNumber = filter (/=5) [0..9] | |
f :: [Int] -> [Int] | |
f [] = [] | |
f [_] = [] | |
f (a:b:xs) = if (a - b /= -1) then a : f (b:xs) else a : g (b:xs) | |
where g ys = map (-1) ys | |
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
"----------------------------" | |
" Target of this config " | |
" - UNIX like OS " | |
" - Cygwin " | |
" - Kaoriya Vim " | |
"----------------------------" | |
"---------------------" |
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
" Vi互換をオフ | |
set nocompatible | |
" filetypeをoffにする | |
filetype off | |
""" Vundle ''' | |
set rtp+=~/.vim/bundle/vundle/ | |
call vundle#rc() | |
" 利用中のプラグインをBundle。コメントは書いちゃダメ。 |
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 java.util.Optional; | |
import java.util.stream.*; | |
public class FizzBuzz8 { | |
public static void main(String[] args){ | |
Stream.iterate(1, n -> n+1) | |
.map( | |
n -> n + ": " + ((n%3)==0 ? (n%5)==0 ? "FizzBuzz" | |
: "Buzz" |
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
"@See http://qiita.com/kamichidu/items/e3e6c16ed84b8f72de1b | |
function! PreviewDatbase(dbFileName, tableName) | |
try | |
let s:C = vdbc#connect_by_dsn('vdbc:sqlite3:dbname=./' . a:dbFileName) | |
let s:data = s:C.select_as_dict('SELECT * FROM '.a:tableName.';') | |
let s:columns = [] | |
for i in items(s:data[0]) | |
call add(s:columns, i[0]) | |
endfor |
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 Control.Monad | |
import Control.Applicative | |
import Control.Exception | |
import System.IO | |
import Data.IORef | |
main = do | |
-- args <- getArgs | |
-- if length args < 1 then | |
-- putStrLn |
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 java.util.concurrent.ConcurrentMap; | |
import java.util.concurrent.ConcurrentHashMap; | |
public class Basics { | |
public static void main(String[] args){ | |
new Basics().main(); | |
} | |
public void main(){ /*{{{*/ |
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
" Inspired by ujihisa's vimrc | |
" And deris's code (http://deris.hatenablog.jp/entry/2013/05/10/003430) | |
function! s:GitLogViewer() | |
if !exists(':VimProcRead') | |
echohl ERROR | |
echo "You don't have vimproc.vim or Your vimproc.vim is invalid ." | |
echo "This plugin required vimproc.vim ." | |
echohl NONE | |
endif |
OlderNewer