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

[¤À¨É] °}¦C±Æ§Ç¤è¦¡

[¤À¨É] °}¦C±Æ§Ç¤è¦¡

Sub TOP_Value()
    '±Æ§Ç
    Dim TT As Variant
   
    TT = Array(5, 4, 2, 1, 2)

    '¥Ñ¤j¨ì¤p±Æ§Ç
    MsgBox Application.WorksheetFunction.Large(TT, 1)
    MsgBox Application.WorksheetFunction.Large(TT, 2)
    MsgBox Application.WorksheetFunction.Large(TT, 3)
    MsgBox Application.WorksheetFunction.Large(TT, 4)
    MsgBox Application.WorksheetFunction.Large(TT, 5)
   
    '¥Ñ¤p¨ì¤j±Æ§Ç
    MsgBox Application.WorksheetFunction.Small(TT, 1)
    MsgBox Application.WorksheetFunction.Small(TT, 2)
    MsgBox Application.WorksheetFunction.Small(TT, 3)
    MsgBox Application.WorksheetFunction.Small(TT, 4)
    MsgBox Application.WorksheetFunction.Small(TT, 5)
End Sub

«D±`·PÁ¦U¦ì«e½ú­Ìªº²Ó¤ß¸ÑÄÀ,Á`ºâ¦³­Ó·§©À,¤£¹L¯uªº­n¼ô½mªº¸Ü,¥i±¤ÁÙ­nªá«Ü¦h®É¶¡;¤£¹L,ÁÙ¥i¥H¤¶²Ð¤@¤U¦³¤°»òªº±¡ªp·|³Ì¦h¥Î¨ì°}¦Cªº¨Ò¤l©O?§Ú¦³¦b§Oªººô¯¸ª¦¹L¤@¤U,¬O§_¦³¤j¶q¦P¤@ºØÃþªº¸ê®Æ¹Bºâ®É¥Î©O?ÁÂÁÂ!!
50 ¦r¸`¥H¤º
¤£¤ä«ù¦Û©w¸q Discuz! ¥N½X

TOP

ÁöµMª©¥D¸ò«e½ú­Ì¸ÑÄÀ¤F«Ü¦h ¤]«Üºë²Ó
¦ý¬OÁÙ¬O¤@ÀYÃú¤ô~ ¬Ý¨Ó­n¦h½m½m¤~¦æ...

TOP

¦^´_ 11# Min


    ·PÁ¦U¦ìª©¥Dªº¥Î¤ß
¥u¬O·í·s¤â­Ì¦b«ôŪªO¥D­Ìªº©«¤l®É
¨C¦ìªO¥Dªº¤å¦r±Ô­z
³£·|¦³¤£¦Pªº¸ÑŪ©Î¬O·Q¹³ªÅ¶¡
©Ó¦p¶{ª©¥D³Ì«á¤@¥y¸Ü..´N¯uªº¬O§Ú­Ìªì¾ÇªÌ»Ý­n«Üª`·Nªº¦a¤è..
¦Ü©óHSª©¥D«h¬O¥H¤¤/°ª¯Å¶¥¼h¦³¤F¸ÑÅÞ¿èÆ[©Àªº¤H¥hÄÄ­zªº..
ÁÂÁª©¥D­Ìªº¦^ÂÐ

TOP

¨þ¨þ¨þ~ ¯uªº­n¹³Hsieh¥S©Ò»¡ ­n¥h­×»y¤å½Òµ{¤F~
GBKEE¥S ¦³´£¨ì! °}¦Cªº½d³ò¬O¥i¥H«ü©wªº!
´N¥Ñ²³æªº¤@ºû°}¦C¨ÓÁ|¨Ò
¤@¯ë¦Ó¨¥ dim arr() ³o¼Ëªº¼gªk ¬O«ü¨S¦³½d³ò¤Î«¬ºA­­¨î ¦ý½d³ò¬O¥Ñ¹w³]ªº0¶}©l
¨º¦pªG¬O¼gdim arr(50 to 100) as string ³o¼Ëªº¼gªk ¬O«ü½d³ò¥Ñ50¶}©lºâ°_ ª½¨ì100 ¸ê®Æ«¬ºA­­¨î¬°¤å¦r«¬ºA

¤]³\·|¦³ªB¤Í»{¬° ¨º¬O¤£¬Oª½±µ¼gdim arr()³o¼Ë´N¦n...
¦ý§Ú­Ó¤H»{¬° ªì¾Ç¹Lµ{ ­n¶VÄYºò¶V¦n! ¦]¬°¶V¼eÃP ¶V¦³¥X¿ù¾÷·|(§Ú«üªº¥X¿ù¬O¬yµ{¥X¿ù ¨Ã«D»yªk¥X¿ù~)

TOP

¦^´_ 9# Hsieh


    ªO¥D
±z¯uªº«Ü¥Î¤ß«Ü»{¯u
¨ä¹ê·í±z¼g¨ì3/4ºû°}¦C®É·í¤Uªºªí¥Ü¤è¦¡¯uªº¬O¤@ÀYÃú¤ô...
¤£¹L·í±zªá®É¶¡¦b¦^Âгo«Ê¥DÃD®É
©Ò¼g¥X¨Óªº°}¦C´N¬Û·í½Ð·¡¤F
¥u¬O·í®É·Q»¡¤£ª¾±z¥i¥H¼g¦¨³o¼Ëªº¤è¦¡¶Ü?
µ²ªG
¬Ý¨ì¦^©«
¥¿¬O·Q­nªí¹Fªº·N«ä
ÁÂÁÂ!!

TOP

¦^´_ 8# PD961A


    §Ú©Ò»¡ªº¬O¦hºû°}¦Cªº·§©À¤j­P´N¹³±Æ¶¤¶°¦X¤@¼Ë
¥u¬O·í§A¦b¼g¦¨°}¦C»Pªk®É¬O¥Î¥LªºINDEXªí¥Ü
¦pDim Ar(0 to 10,0 to 20,0 to 10,0 to 30)
³o¼Ë´N«Å§i¤F¤@­Ó4ºû°}¦C
¥u­q¥X³o°}¦C¤¤²Ä¤@­Ó¤¸¯À´N¼g¦¨
Ar(0,0,0,0)
³Ì«á¤@­Ó¤¸¯À´N¬OAr(10,20,10,30)
²Ä¤@ºû¦³11­Ó¤¸¯À
²Ä¤Gºû¦³21­Ó¤¸¯À
²Ä¤Tºû¦³11­Ó¤¸¯À
²Ä¥|ºû¦³11­Ó¤¸¯À

Sub nn()
Dim Ar(11, 21, 11, 31)
For i = 0 To 10
   For j = 0 To 20
      For x = 0 To 10
         For y = 0 To 30
              Ar(i, j, x, y) = i + j + x + y: Next: Next: Next: Next
For i = 0 To 10
   For j = 0 To 20
      For x = 0 To 10
         For y = 0 To 30
              MsgBox "Ar(" & i & "," & j & "," & x & "," & y & ")=" & i & "+" & j & "+" & x & "+" & y & "=" & Ar(i, j, x, y): Next: Next: Next: Next
              
End Sub
¾Ç®üµL²P_¤£®¢¤U°Ý

TOP

¦^´_ 6# Hsieh

ªO¥D±zªº²LÅã©öÀ´ªí¹F¤è¦¡..¦b¼g¨ì3ºû¤Î4ºû«á..¤Ï¦ÓÅý¤H¤£ª¾©Ò¤ª..
   
¶{ªO¥D±Ô­z´N¤@ºû°}¦Cªº«¬ºA
dim arr()
arr(0) arr(1) arr(2)....arr(65536)
¦ý¶·ª`·Nªº¬Oarray¹w³]¬O¥Ñ0¶}©l!

¤Gºû°}¦C§ó¬O²³æ excelªºcells¥»¨­´N¬O¤Gºû
cells(1,1) ´N¦p¦Parr(0,0)
cells(123,321) ´N¦p¦Parr(123,321)ªº¦^µª
©Mgbkeeª©¥D©Ò»¡ªº³£¤@¼Ë...
©Ò¥HÀ³¸Ó¬O¶¥¯ÅÁÙ¤£¨ì¼g¥X3ºû©Î4ºûªº°}¦C
¦]¦¹¨S¿ìªk·Q¹³
ÁÙ¬OÁÂÁ±z!

TOP

¦^´_ 4# Min
´N­«¤@ºû°}¦Cªº«¬ºA¶}©l»¡°_...
¥Hexcel cells¨Ó»¡ ¤@ºû°}¦C´N¹³¬O¥u¦³¤@Ä檺¸ê®Æ«¬ºA ex.¥u¦³A1~A65536

¦pªG:A = [A1:A65536]   ¾ãÄæ
A¬O(1  To 65536 ,  1) ªº¤Gºû°}¦C   
¦pªG:A = [A1:IV1]         ¾ã¦C
A¬O(1 , 1 To 256 ) ªº¤Gºû°}¦C

TOP

¥»©«³Ì«á¥Ñ Hsieh ©ó 2010-5-7 21:54 ½s¿è

¦^´_ 5# PD961A


    ²LÅã©öÀ´ªº¤å¦r±Ô­z?
¨º¦U¦ìª©¥D´N¥ý¨Ó¥h­×»y¤å½Òµ{
§â»y¨¥ºë·Ò«á¦A¨Óµo¤å
¶}¶}ª±¯º°Õ!
°}¦C:
¬Û«H¹ï¤@ºû°}¦Cªº¸Ü¤j®a¤ñ¸û®e©ö±µ¨ü
´N¤@°ï¸ê®Æ³W«hªº©ñ¤J¤@±Æ¤º´N¬O¤@ºû°}¦C
¥H¹êª«Á|¨Ò
¤j®a¦³¤W¹L¾Ç,¾Ç®Õ¦³´Â·|©Î¥ô¦ó¥þ®Õ¨ì¾Þ³õ¶°¦Xªº¸gÅç§a!
·í­n¦U¯Z¾ã¶¤®É
¯Zªø»¡±ÆÀY¥î¬°·Ç
³o¤@¥îªº¦¨­û´N¬O¤@ºû°}¦Cªº¤¸¯À
§Ú­Ì§â³o±ÆÀY©³¤U­n¹ï»ô¥Lªº³o¨Ç¤H
´N¬O¤Gºû°}¦Cªº²Ä¤Gºûªº¤¸¯À¤F
¦A§â¶°¦X¦nªº¯Z¯Å(¤Gºû°}¦C)
±a¨ì¾Þ³õ®É
¾Þ³õ¤W·|¤À¦~¯Å¯¸¦n
¨C¤@­Ó¦~¯Å´N·|¦³¦n¦h¯Z
³o¤@­Ó¦~¯Å´N¬O¦h­Ó¤Gºû°}¦Cªº¶°¦X(¤Tºû°}¦C)
¨C­Ó¾Ç®Õ·|¦³¦h­Ó¦~¯Å
¨º¶°¦X³o»ò¦h¦~¯Å(¤Tºû°}¦C)´N¦¨¤F¥|ºû°}¦C
³o¼Ë¹ï°}¦Cªº¸ÑÄÀ¤£ª¾¬O§_¤ñ¸û¹êÅé¤Æ
¤ñ¸û®e©ö¤F¸Ñ©O?
  1. Sub nn()
  2. Dim Ar(3, 10, 10, 4) '©w¸qAr¬°4ºû°}¦C:¨C¶¤4±Æ,¨C±Æ10¤H,¨C¦~¯Å¦³10¯Z,¦@¦³3­Ó¦~¯Å(¦~¯Å,¯Z,¤H,±Æ)
  3. k = 42048
  4. mystr = Chr(k)
  5. For y = 0 To 2
  6.    For x = 0 To 9
  7.        For i = 0 To 3
  8.          For j = 0 To 9
  9.          Do Until mystr <> "?"
  10.          k = k + 1
  11.          mystr = Chr(k)
  12.          Loop
  13.               Ar(y, x, j, i) = Chr(k): k = k + 1: mystr = Chr(k): Next: Next: Next: Next
  14. For y = 0 To 2
  15.    For x = 0 To 9
  16.        For i = 0 To 3
  17.          For j = 0 To 9
  18.              Cells(r + 1, 1) = y + 1 & "¦~" & x + 1 & "¯Z²Ä" & i + 1 & "±Æ²Ä" & j + 1 & "¦ì¦P¾Ç©m:": _
  19.              Cells(r + 1, 2) = Ar(y, x, j, i): r = r + 1: _
  20.              Next: Next: Next: Next
  21. End Sub
½Æ»s¥N½X
¾Ç®üµL²P_¤£®¢¤U°Ý

TOP

        ÀR«ä¦Û¦b : ¡i¬O§_µo´§¤F¨}¯à¡H¡j¤H¶¡¹Ø©R¦]¬°µu¼È¡A¤~§óÅã±o¬Ã¶Q¡CÃø±o¨Ó¤@½ë¤H¶¡¡AÀ³°Ý¬O§_¬°¤H¶¡µo´§¤F¦Û¤vªº¨}¯à¡A¦Ó¤£­n¤@¨ý¨Dªø¹Ø¡C
ªð¦^¦Cªí ¤W¤@¥DÃD