LeetCode-66

Links:https://leetcode.com/problems/plus-one/

Given a non-negative number represented as an array of digits, plus one to the number.

The digits are stored such that the most significant digit is at the head of the list.

 

题目大意:给出一个用数组存储的整数,高位在前…例如:123在数组内为[1][2][3]。

返回+1后的值.

注意进位的情况…(99999+1)…

【LeetCode】66. Plus One
Tagged on:
0 0 投票数
Article Rating
订阅评论
提醒

0 评论
最新
最旧 最多投票
内联反馈
查看所有评论