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
public class sample { | |
public static void main(String[] args){ | |
SampleFunction function = (name) ->System.out.println("Hello, " + name); | |
function.say("テスト 太郎"); | |
} | |
@FunctionalInterface | |
private interface SampleFunction { |
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
apply plugin: 'java' | |
apply plugin: 'eclipse' | |
sourceCompatibility = 1.5 | |
version = '1.0' | |
jar { | |
manifest { | |
attributes 'Implementation-Title': 'Gradle Quickstart', 'Implementation-Version': 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
/// <reference path='typings/tsd.d.ts' /> | |
//関数定義 | |
var countFruitsFromLines = (list:string[]) => { | |
return _ | |
.chain(list) | |
.map(function (_list) { | |
//文字列分割の処理を配列の中身に行う。 | |
return _list.split(' '); | |
}) |
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
/// <reference path='typings/tsd.d.ts' /> | |
//関数定義 | |
var countFruitsFromLines = (list:string[]) => | |
_.chain(list) | |
// 文字列分割の処理を配列の中身にそれぞれ行い、配列を新たに生成して返す。 | |
.map((_list:string[]) => _list.split(' ')) | |
// 階層的リストに対しても全て展開して、階層がない配列に変換して返す。 | |
.flatten() | |
// 配列の要素をカウントし、それぞれの要素とその出現回数をキー値として格納したオブジェクトを返す。 |
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" | |
) | |
func main() { | |
fmt.Println(calcPalindromicNumber(9)) | |
fmt.Println(calcPalindromicNumber(10)) | |
} |
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
String.prototype.reverse = function () { | |
return this.split("").reverse().join(""); | |
}; | |
function calcPalindromicNumber(num) { | |
for (var i=num;; i++) { | |
if (i % 2 === 0) { | |
continue; | |
} | |
if (i.toString() === i.toString().reverse() && |
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 calcPalindromicNumber(num) | |
i = num; | |
loop { | |
if i.to_s == i.to_s.reverse && | |
i.to_s(8) == i.to_s(8).reverse && | |
i.to_s(2) == i.to_s(2).reverse | |
return i | |
end | |
i+=1 | |
} |
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" | |
"text/scanner" | |
"strings" | |
"strconv" | |
) | |
func 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
package main | |
import ( | |
"fmt" | |
"text/scanner" | |
"strings" | |
"strconv" | |
) | |
func 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
Effective Java 全10章 全項目78 | |
4/5 2-4章(3章分) | |
4/12 5-8章(4章分) | |
4/19 10-11章(3章分) | |
4/26 予備週 | |
リファクタリング 1-12章(6章-12章がメイン) | |
5/10 1-6章(6章分) | |
5/17 7-9章(3章分) | |
5/24 10-12章(3章分) |
OlderNewer