c
Take as input an array of digits (e.g. x = [1 2 3]) and output an array of digits that is that number "incremented" properly, (in this case, y = [1 2 4]).
Examples of proper input/output:
x = [1 9 1 9] ----> y = [1 9 2 0]
and
x = [9 9 9] ----> y = [1 0 0 0]
有人有干净的方法吗?
解决方案559576.
如何摆脱循环?
简单地用:y = yy - '0'或:y = yy - 48替换for循环。
斐波纳契序列
10732个求解器
回到基础26 - 关键词
325个议员
03 - 矩阵变量5
495个求解器
将单元数组转换为数组
666个求解器
找到最近的素数
583个求解器
格拉特数目三角形
91个议员
魔法!
282个求解器
Hitchhiker的Matlab指南
2990个议员
调整你的吉他
解决115
我的妻子对吗?现在更有错误的丈夫
1268个议员
找到Matlab Central中的宝藏,并发现社区如何帮助您!
选择一个网站,以便在可用的地方进行翻译内容,并查看本地活动和优惠。根据您的位置,我们建议您选择:。
您还可以从以下列表中选择一个网站:
选择中国网站(以中文或英文)以获得最佳网站性能。其他MathWorks国家网站未优化您所在地的访问。
联系您当地的办公室