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
package main | |
import ( | |
"fmt" | |
"math" | |
) | |
func Sqrt(x float64) float64 { | |
z := 1.0 | |
for { |
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
package main | |
import ( | |
"fmt" | |
"io/ioutil" | |
"log" | |
) | |
func main() { | |
file, err := ioutil.ReadFile("for.go") |
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
/* <system section="theme" selected="11696248318757940905"> */ | |
@import url("http://hatenablog.com/theme/11696248318757940905.css"); | |
/* </system> */ | |
#blog-title { | |
border-top: none; | |
} | |
.entry { | |
border-bottom: none; | |
} |
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
# -*- coding: utf-8 -*- | |
require 'mechanize' | |
require 'pit' | |
require 'uri' | |
pit = Pit.get('hatena', :require => { | |
'username' => 'username', | |
'password' => 'password'}) | |
BASE = URI("http://graph.hatena.ne.jp/#{pit['username']}/") |
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
#!/usr/bin/env ruby | |
require 'pit' | |
require 'mechanize' | |
require 'uri' | |
pit = Pit.get('github', :require => { | |
'username' => 'username', | |
'password' => 'password'}) | |
BASE = URI('http://gist.github.com/') |
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
- hosts: vm | |
sudo: yes | |
tasks: | |
- apt: update_cache=yes | |
- apt: name=zsh state=present | |
- apt: name=git state=present | |
- apt: name=emacs state=present | |
- apt: name=vim state=present | |
- apt: name=golang state=present | |
- apt: name=gist state=present |
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
def default_value | |
p 'generate default_value' | |
'default value' | |
end | |
def some_method(param = nil) | |
param ||= default_value | |
p param | |
end | |
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
def default_value | |
p 'generate default_value' | |
'default value' | |
end | |
def some_method(param = nil) | |
param ||= default_value | |
p param | |
end | |
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
- name: Get latest peco version | |
shell: > | |
curl -sI https://github.com/peco/peco/releases/latest | awk -F'/' '/^Location:/{print $NF}' | |
register: peco_latest_version |
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
[localhost] | |
127.0.0.1 |
OlderNewer