Skip to content

Instantly share code, notes, and snippets.

View tamanyan's full-sized avatar
🤩

Taketo Yoshida tamanyan

🤩
View GitHub Profile
@tamanyan
tamanyan / nuxt-style-guide.md
Last active August 21, 2019 10:23
Style Guide
Good
const AppHeader = () => import('~/components/AppHeader.vue')
const AppFooter = () => import('~/components/AppFooter.vue')

Bad
import AppHeader from '~/components/AppHeader.vue'
import AppFooter from '~/components/AppFooter.vue'
## 開発環境面
- MacBook Pro
- ネットワークアクセスの自由さ
## 待遇面
年俸はA$160kが希望です
(三菱商事の年収、駐在費やオーストラリアのシニアデータサイエンティストやコンサルタントの年収を参考にしました)
@tamanyan
tamanyan / home_visitor_pitching_result.csv
Created January 21, 2017 09:40
2011年~2015年の各チームの投手成績
HOME_K VISITOR_IP Team VISITOR_K Year HOME_BB VISITOR_BB HOME_IP
508 625 Giants 484 2015 180 195 646
505 620+1/3 Buffaloes 450 2015 215 261 643
506 624+2/3 Eagles 517 2015 208 248 663
527 630+1/3 Carp 483 2015 217 202 656
581 608+1/3 Tigers 509 2015 214 238 664
455 621+2/3 Marines 471 2015 212 216 643
501 622+2/3 Fighters 492 2015 253 218 654
444 607 Lions 429 2015 235 252 658
626 627+1/3 Hawks 503 2015 204 223 672
mixOf = (base, mixins...) ->
class Mixed extends base
for mixin in mixins by -1 #earlier mixins override later ones
for name, method of mixin::
Mixed::[name] = method
Mixed
class DeepThought
answer: ->
42
@tamanyan
tamanyan / ConvenientLocation.java
Last active December 22, 2015 02:58
AOJ - Problem 0189 : Convenient Location
/**
* @author Taketo Yoshida
*/
import java.util.*;
public class ConvenientLocation {
private Solver solver;
public class Pair<F, S> {
private F first; //first member of pair
@tamanyan
tamanyan / RoadOrFlight.java
Last active December 22, 2015 01:59
TopCoder SRM 468 DIV 2 250
/**
* @author Taketo Yoshida
*/
public class RoadOrFlight {
private Solver solver;
enum SolverType { DP, FULL_SEARCH, MEMODFS }
class SolverNotFoundException extends Exception {
public SolverNotFoundException(String msg) { super(msg); }
}
@tamanyan
tamanyan / TopCoderTemplate.cpp
Last active December 22, 2015 00:00
TopCoderTemplate CPP file
//include
//------------------------------------------
#include <vector>
#include <list>
#include <map>
#include <set>
#include <deque>
#include <stack>
#include <bitset>
#include <algorithm>
@tamanyan
tamanyan / consistent-hashing.rb
Last active December 21, 2015 19:09
consistent hashing hash selection algorithm
def getHash(hashes, val)
start = 0
finish = hashes.size - 1
val = val % hashes[finish]
if hashes[start] >= val
return hashes[0]
end
mid = start
@tamanyan
tamanyan / InfiniteSequence.java
Last active December 21, 2015 17:29
TopCoder SRM413 Div1Medium
/**
* @author Taketo Yoshida
*/
import java.util.*;
public class InfiniteSequence {
private Solver solver;
enum SolverType { DP, DFS, MEMODFS }
class SolverNotFoundException extends Exception {