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
(function () { | |
alert('this is a sample snipet. My First Github Gist Using.') | |
})(); |
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
var fs = require('fs'); | |
var zlib = require('zlib'); | |
// ファイルを読み込みます | |
var gzipContent = fs.readFileSync('./hello.txt.gz'); | |
// 解凍します | |
zlib.gunzip(gzipContent, function (err, binary) { | |
// ファイルに出力します |
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
◆導入:誰向けか、何を提供するのか、なぜ話すのか(2分) | |
・自己紹介 | |
・社内外の勉強会で登壇したいと思っているが、プレゼン制作が難しいと考えている人 | |
・プレゼンテーション制作において1つの道を示す | |
・プレゼンテーションスキルは情報を伝えるだけではなく、人の心を動かす力もある | |
◆主題:プレゼンテーションの準備にはステップがある(1分) | |
・パワポなどプレゼン制作ツールを最初から開いて悩むのはダメ。 | |
・プレゼン作りには順序があり、それに従えば誰でも簡単に魅了的なプレゼンが作れる。 | |
・その順序は大きく分けて3つ。「話の構成作り」「資料作り」「極める」 |
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
// 変数の定義(型を推定する) | |
var str = "Hello, playground" | |
var intValue = 1; | |
// 変数の定義(型を明示する) | |
var str2:String = "Good Night"; | |
// 変数の定義 | |
// 初期値も代入せず、型も定義しない場合には、エラーとなる | |
//var type; |
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
""" | |
G's ACADEMY TOKYO からメンター画像を取得するサンプル. | |
""" | |
import os | |
from urllib.request import urlopen | |
from pprint import pprint | |
from bs4 import BeautifulSoup | |
# メンター一覧ページのHTMLを取得します. | |
with urlopen("http://gsacademy.tokyo/mentor/") as res: |
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
<?php | |
// レスポンスヘッダーをJSONに指定する | |
header('Content-Type: application/json'); | |
// 例えば、以下のデータを返したい場合に | |
$user = array( | |
'id' => 1, | |
'name' => 'Yohei' | |
); |
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" | |
) | |
type UserModel interface { | |
Find() (User) | |
} |
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
""" | |
Google Geocoding API を用いて、位置情報などを扱う. | |
""" | |
import os | |
import json | |
import time | |
import re | |
import csv | |
from pprint import pprint | |
from collections import OrderedDict |
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
var paymentRequest = stripe.paymentRequest({ | |
country: 'JP', | |
currency: 'jpy', | |
total: { | |
label, | |
amount: price, | |
}, | |
requestPayerName : !!(item.item_type === QR_ITEM_TYPE_URL_LINK && item.pay_name_required), | |
requestPayerEmail : !!(item.item_type === QR_ITEM_TYPE_URL_LINK && item.pay_email_required), | |
requestPayerPhone : !!(item.item_type === QR_ITEM_TYPE_URL_LINK && item.pay_tel_required), |
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
// 検索される時に呼び出される. | |
func searchBarSearchButtonClicked(_ searchBar: UISearchBar) { | |
// キーボードを閉じます. | |
searchBar.resignFirstResponder() | |
// 検索ワードがなければ終了. | |
guard let searchTerm = searchBar.text else { | |
return | |
} |
OlderNewer