摘要: Given a binary tree and a sum, determine if the tree has a root-to-leaf path such that adding up all the values along the path equals the given sum.Fo... 阅读全文
posted @ 2015-05-21 22:15 wy1290939507 阅读(141) 评论(0) 推荐(0) 编辑
摘要: 如果一个数的每个位的整数的平方和等于1,则为happy numberExample:19 is a happy number12+ 92= 8282+ 22= 6862+ 82= 10012+ 02+ 02= 1#include#include#include using namespace std... 阅读全文
posted @ 2015-05-21 11:03 wy1290939507 阅读(138) 评论(0) 推荐(0) 编辑