如何遍历元素而不使用循环来执行添加? [英] How to traverse through elements without using loop to perform addition?

查看:95
本文介绍了如何遍历元素而不使用循环来执行添加?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在不使用循环的情况下遍历元素以添加整数?

Any way to traverse through the elements to add the integers without using a loop?

推荐答案

无论是编写代码还是调用代码,都必须循环这样做的库例程。

另一种选择是递归,但这就是疯狂。
Something will have to loop, whether you write the code or call a library routine that does it.
The other option would be recursion, but that way madness lies.


这篇关于如何遍历元素而不使用循环来执行添加?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆