【leetcode_easy_math】1317. Convert Integer to the Sum of Two No-Zero Integers

problem

1317. Convert Integer to the Sum of Two No-Zero Integers

solution#1:检查数值中是否含有字符0;

code:

solution#2: 通过判断除以10的余数来判断是否含有符号0;

code:

注意,理解题目的意思,要求两个加数中不包含数字0;主要是怎么确定是否含有数字0;

参考

1. leetcode_easy_math_1317. Convert Integer to the Sum of Two No-Zero Integers;

做自己该做的事情,做自己喜欢做的事情,安静做一枚有思想的技术媛。
版权声明,转载请注明出处:https://www.cnblogs.com/happyamyhope/
原文地址:https://www.cnblogs.com/happyamyhope/p/13953491.html