朝花夕拾

Clicks&Changes

导航

2015年10月6日 #

Single Number

摘要: Given an array of integers, every element appearstwiceexcept for one. Find that single one.Your algorithm should have a linear runtime complexity. C... 阅读全文

posted @ 2015-10-06 14:03 Draug 阅读(93) 评论(0) 推荐(0) 编辑

Digital root(数根)

摘要: 关于digital root可以参考维基百科,这里给出基本定义和性质。一、定义 数字根(DigitalRoot)就是把一个数的各位数字相加,再将所得数的各位数字相加,直到所得数为一位数字为止。而这个一位数便是原来数字的数字根。适用范围为正整数和零。例如:65536,6+5+5+3+6=25,2+5... 阅读全文

posted @ 2015-10-06 13:51 Draug 阅读(462) 评论(0) 推荐(0) 编辑