示例#1
0
文件: pe.go 项目: Horimotsu/PEGo
/*
Solve012 solves Project Euler 012
*/
func Solve012() (ans int) {
	for i := 0; ; i++ {
		ans = peb.SumN(i)
		if peb.NumOfDivisors(ans) > 500 {
			break
		}
	}
	return
}
示例#2
0
文件: pe.go 项目: Horimotsu/PEGo
/*
Solve006 solves Project Euler 006
*/
func Solve006() (ans int) {
	ans = peb.SumN(100)*peb.SumN(100) - peb.SumN2(100)
	return
}