Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Print as per the value entered for the variable.
#2
Solved: 11 Years, 3 Months, 3 Weeks ago
Hi,

Here we go...
Code:
temp=""
N=5
For i=1 to N
     temp=temp&"*"
Next
msgbox temp

In the same way you can play with below examples as well.
Execute the below code and see Smile


Code:
For j=1 to 10
      temp=""
     For i=1 to j
         temp=temp&"*"
    Next
      print temp
Next

Code:
For j=10 to 1 step-1
      temp=""
     For i=j to 1 step-1
         temp=temp&"*"
    Next
      print temp
Next

Reply


Messages In This Thread
RE: Print as per the value entered for the variable. - by sreekanth chilam - 10-18-2011, 10:33 PM

Forum Jump:


Users browsing this thread: 4 Guest(s)