- ©«¤l
- 7
- ¥DÃD
- 4
- ºëµØ
- 0
- ¿n¤À
- 11
- ÂI¦W
- 0
- §@·~¨t²Î
- winxp
- ³nÅ骩¥»
- visual studio 2008
- ¾\ŪÅv
- 10
- ©Ê§O
- ¨k
- µù¥U®É¶¡
- 2015-6-26
- ³Ì«áµn¿ý
- 2015-11-11
|
¤U¦C¬O¥D±±¥xÀ³¥Îµ{¦¡¡A·í§Ú°õ¦æ¿é¤J¼ÆȬ°5®É,Åã¥Ü¦p¹Ï1¡A·í§Ú°õ¦æ¿é¤J¼ÆȬ°10®É,Åã¥Ü¦p¹Ï2¡A½Ð°Ý¦U¦ì¹Ï2ªº¿é¥X¦p¦ó¹³¹Ï1¤@¼Ë¡Hµ{¦¡½X¬õ¦â¦r³¡¥÷n¦p¦ó§ï©O¡H
Module Module1
Sub Main()
Dim sum, i, n As Integer
Console.WriteLine("=¨D¨ì100¥i¥H³Qn¾ã°£ªº¾ã¼Æ=")
Console.WriteLine()
Console.Write("½Ð¿é¤J1¨ì100ªº¾ã¼Æn¡G")
n = CInt(Console.ReadLine())
If n >= 1 And n <= 100 Then
Do While sum + n <= 100
sum += n
Console.Write("{0},", sum)
i += 1
If i Mod n = 0 Then
Console.WriteLine()
End If
Loop
Console.WriteLine()
End If
Console.ReadKey()
End Sub
End Module |
-
-
1.jpg
(13.14 KB)
¹Ï1
-
-
2.jpg
(11.42 KB)
¹Ï2
|