English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

can anyone write the coding for:
5
5 4
5 4 3
5 4 3 2
5 4 3 2 1
anyone??

2006-06-28 00:02:16 · 3 answers · asked by priyanshu2606 2 in Computers & Internet Programming & Design

3 answers

Dim strLine As String, Dim I as Integer
I = 5
For L = I To 1 Step -1
strLine = strLine & " " & L
Debug.Print strLine
Next L

Hope that will do it!

Helmut

2006-06-28 01:07:10 · answer #1 · answered by hswes 2 · 0 0

I have 2 answers because I understood the question in 2 different ways.

Answer 1:

i=5
do
print i
i=i-1
loop while i>0

-------------------------------
Answer 2:

i=5
b= i
do
for a=i to b step -1
print a
next a
b= b-1
loop while b>0

2006-06-28 07:23:12 · answer #2 · answered by Paul_G 2 · 0 0

I can do it for you but I wont because if I do it then you wont learn will you?

So if you wish to learn then use link below and good luck.

http://www.softcircuits.com/sw_vbsrc.htm

2006-06-28 07:17:50 · answer #3 · answered by Joe_Young 6 · 0 0

fedest.com, questions and answers