嵌套循环有人请帮忙!我只需要3号和4号 [英] Nested loops someone please help! I only need no.3 and 4
本文介绍了嵌套循环有人请帮忙!我只需要3号和4号的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
编写一个程序,使用嵌套循环显示以下四(4)个数字网格。您的输出应如下:
(1)
1
12
123
1234
12345
(2)
1
21
321
4321
54321
(3)
5 6 7 8 9
4 5 6 7 8
3 4 5 6 7
2 3 4 5 6
1 2 3 4 5
/ b
(4)
54321
4321
321 >
21
1
Write a program that displays the following four (4) grids of numbers using nested loops. Your output should be as follows:
(1)
1
12
123
1234
12345
(2)
1
21
321
4321
54321
(3)
5 6 7 8 9
4 5 6 7 8
3 4 5 6 7
2 3 4 5 6
1 2 3 4 5
(4)
54321
4321
321
21
1
推荐答案
你只是为了学习一些东西而给你的家庭作业。如果您使用别人的帮助,您将不会利用学校给您的机会。不要失去你的机会 - 生命太短暂,不足以学习,后来,相信我,赶上并学习你错过的东西会越来越难。不要浪费一秒钟,你自己完成家务。
-SA
You have been give your home assignments just to learn something. If you use someone else's help, you won't use the chance your school gives you. Don't loose your chance — the life is too short to learn enough, and later on, believe me, it would be increasingly difficult to catch up and learn things that you have missed. Don't waste a second, do you home assignments all by yourself.
—SA
这篇关于嵌套循环有人请帮忙!我只需要3号和4号的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文