原文:[LeetCode] 829. Consecutive Numbers Sum 连续数字之和

Given a positive integer N , how many ways can we write it as a sum ofconsecutive positive integers Example : Example : Example : Note: lt N lt . 这道题给了一个正整数N,问N能写成多少种连续正整数之和,比如 可以写成 ,或者 。这道题其实不好做,因为没 ...

2019-09-26 23:54 2 1051 推荐指数:

查看详情

 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM