标签:style blog http color java os strong io
题目:
Given two numbers represented as strings, return multiplication of the numbers as a string.
Note: The numbers can be arbitrarily large and are non-negative.
题解:
题意就是给你两个字符串型的数字,给这两个数字做乘法。
如果直接转换成Integer做乘法就会溢出。
所以要一步一步来。
下面讲解引用自(http://leetcodenotes.wordpress.com/2013/10/20/leetcode-multiply-strings-%E5%A4%A7%E6%95%B4%E6%95%B0%E7%9A%84%E5%AD%97%E7%AC%A6%E4%B8%B2%E4%B9%98%E6%B3%95/comment-page-1/#comment-122),非常精巧的写法:
这个题第二遍做code就写的挺完美的,高兴~~几个要点:
代码如下:
Multiply Strings leetcode java,布布扣,bubuko.com
Multiply Strings leetcode java
标签:style blog http color java os strong io
原文地址:http://www.cnblogs.com/springfor/p/3889706.html