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 java.util.concurrent.RecursiveTask; | |
import java.util.concurrent.ForkJoinPool; | |
public class Fib7 extends RecursiveTask<Integer>{ | |
private final int n; | |
Fib7(int n){ | |
this.n = n; | |
} |
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 java.util.*; | |
import java.util.concurrent.*; | |
public class Fib5 { | |
private ExecutorService exec = Executors.newCachedThreadPool(); | |
public class Task implements Callable<Integer> { | |
private final int n; |
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
# -*- coding: utf-8 -*- | |
import matplotlib.pyplot as plt | |
import numpy as np | |
def main(): | |
n = 30 | |
fib_list = [] | |
rate_list = [] |
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 java.io.*; | |
import org.apache.commons.csv.CSVRecord; | |
import org.apache.commons.csv.CSVFormat; | |
public class Csv{ | |
public static void main(String[] args){ | |
try{ | |
String homeDir = System.getenv("HOME"); | |
Reader reader = new FileReader(homeDir + "/dev/lrn/java/file/read.csv"); | |
FileWriter writer = new FileWriter(homeDir + "/dev/lrn/java/file/write.csv"); |
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
# coding:utf-8 | |
from sklearn import cluster, datasets | |
import pandas as pd | |
import numpy as np | |
from matplotlib import pyplot as plt | |
from mpl_toolkits.mplot3d import Axes3D | |
# このデータが曲者で、数値データの中に英字や記号が混ざってた | |
df = pd.read_csv("scrubbed.csv") |
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 java.io.*; | |
import java.util.*; | |
import java.util.concurrent.*; | |
public class IOByExec implements Runnable{ | |
private ExecutorService exec = Executors.newCachedThreadPool(); | |
private String name; | |
private int count; | |
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>1行が2段組のテーブルを縞々に表示する</title> | |
<style type="text/css"> | |
.table-striped-2span tbody tr:nth-of-type(4n+1), .table-striped-2span tbody tr:nth-of-type(4n+2) { | |
background-color: #c0c0c0; | |
} | |
</style> |
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
.column{ | |
font-size:42px; | |
width:100%; | |
} | |
.item-box{ | |
background-color:white; | |
} | |
.js-column-header{ | |
display:none; | |
} |
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
{ | |
// Place your snippets for python here. Each snippet is defined under a snippet name and has a prefix, body and | |
// description. The prefix is what is used to trigger the snippet and the body will be expanded and inserted. Possible variables are: | |
// $1, $2 for tab stops, $0 for the final cursor position, and ${1:label}, ${2:another} for placeholders. Placeholders with the | |
// same ids are connected. | |
// Example: | |
// "Print to console": { | |
// "prefix": "log", | |
// "body": [ | |
// "console.log('$1');", |
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
cmd=$1 | |
stack_name=$2 | |
if [ $cmd = "create" ]; then | |
case $3 in | |
"") echo "Error: Please give a template file path!"; exit 0;; | |
/*) absolute=$3 ;; | |
*) absolute=$PWD/$3 ;; | |
# S3にはこれから対応する、かも | |
esac |