发信人: batixu (Ninny), 信区: JobHunting
标 题: MS一道面试题
发信站: BBS 未名空间站 (Fri Oct 10 14:27:32 2008)
Write a function that prints out all sets of consecutive integers that add
up to all and any numbers within a given range. For example, given a range
of 4-9, your function must print out the fact that 5=2+3, 6=1+2+3, 7=3+4, 9=
2+3+4, 9=4+5.
Friday, October 10, 2008
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment