ªð¦^¦Cªí ¤W¤@¥DÃD µo©«

°Ý¤@­Ó"¥Î1ºûarray·í¦h­p¼Æ¾¹"¼gªkªº°ÝÃD

°Ý¤@­Ó"¥Î1ºûarray·í¦h­p¼Æ¾¹"¼gªkªº°ÝÃD

HI ¤j®a¦n¡A
     ¤pªº·Q½Ð°Ý­Y§Ú­n¥Î¤@ºû°}¦C¦@10­Óelements ·í§@counter¤§Àx¦sªÅ¶¡¡A¸g¹L«e¸m¨BÆJ(mod)«á¡A¤ÀÃþ¨ì10­Ó¶°¦X¤¤ªº¨ä¤¤¤@­Ó¶°¦Xelement(¤]´N¬O¨ä¤¤¤@­Ócounter)´N¥[1
     ¸Ó«ç»ò¼g?   

     ¥Ø«e¤j¬ù¦³15'000¡A30'000¡A45'000¤TºØ¤j¤pªºdata­n¥á¤J(<=³oÀ³¸Ó¤£¬O­«ÂI!)

      ÁÂÁ¦U¦ì¬Ý§¹§Úªº°ÝÃD

¥»©«³Ì«á¥Ñ register313 ©ó 2012-5-7 21:21 ½s¿è

¦^´_ 1# m09903020

ÃD¥Ø¥u»¡¤@¥b
¥ý°Ñ¦Ò
  1. Sub xx()
  2. Dim Ar(9)
  3. For I = 1 To [A1]
  4.   Y = I Mod 10
  5.   Ar(Y) = Ar(Y) + 1
  6. Next I
  7. [D1].Resize(10, 1) = Application.Transpose(Ar)
  8. End Sub
½Æ»s¥N½X
  1. Sub yy()
  2. Dim Ar(9)
  3. X = Int([A1] / 10)
  4. Y = [A1] Mod 10
  5. For I = 0 To 9
  6.   Ar(I) = X
  7.   If I <= Y Then Ar(I) = Ar(I) + 1
  8. Next I
  9. Ar(0) = Ar(0) - 1
  10. [D1].Resize(10, 1) = Application.Transpose(Ar)
  11. End Sub
½Æ»s¥N½X
1.gif

TOP

        ÀR«ä¦Û¦b : ¡i¥Í©R¦b©I§l¶¡¡j¦òªû»¡¡G¡u¥Í©R¦b©I§l¶¡¡C¡v¤HµLªkºÞ¦í¦Û¤vªº¥Í©R¡A§óµLªk¾×¦í¦º´Á¡AÅý¦Û¤v¥Ã¦í¤H¶¡¡C¬JµM¥Í©R¥h¨Ó³o»òµL±`¡A§Ú­Ì§óÀ³¸Ó¦n¦n¦a·R±¤¥¦¡B§Q¥Î¥¦¡B¥R¹ê¥¦¡AÅý³oµL±`¡BÄ_¶Qªº¥Í©R¡A´²µo¥¦¯uµ½¬üªº¥ú½÷¡A¬M·Ó¥X¥Í©R¯u¥¿ªº»ù­È¡C
ªð¦^¦Cªí ¤W¤@¥DÃD