thaiall logomy background
coding : sort. shell.asp.
my town
Source : Perl | PHP | ASP | JSP | HTML | HTML5 | JavaScript | Java | COBOL | C++ | MS Access | VBNet | VB | Python | โค้ดดี
File : shell.asp. ID : 2206
Skin : Default | Sons-of-obsidian | Sunburst | Highlighter | Full
<%
dim numamt, nummax, nummin, ar(100), itmp, jtmp, ktmp
numamt = 5 : nummax = 100 : nummin = 50
response.write("Before sorted by shell sort<br>")
randomize
for i = 1 to numamt 
  ar(i) = int(nummin  + (rnd * ( nummax - nummin + 1 )))
  response.write( i & " : " & ar(i) & "<br>")                
next
itmp = 1
for j = 2 to numamt
  jtmp=ar(j)    
  ktmp= j - 1
  if itmp = 0 then
    itmp = itmp + 1
    ar(itmp) = jtmp
  end if
  do while jtmp < ar(ktmp) and ktmp > 0 and ktmp <= numamt
    ar(ktmp + 1) = ar(ktmp)
    ktmp = ktmp - 1
  loop
  ar(ktmp + 1) = jtmp
next
response.write("<hr>After sorted by shell sort<br>")
for i = 1 to numamt  
  response.write( i & " : " & ar(i) & "<br>")                
next
%>
จำนวน : 28 บรรทัด
าษาเฮชทีเอ็มแอล (HTML = HyperText Markup Language) คือ ภาษาคอมพิวเตอร์ที่ออกแบบมาเพื่อใช้ในการสร้างเว็บเพจที่เรียกดูผ่านทางเว็บเบราว์เซอร์ (Web Browser) เริ่มพัฒนาโดย ทิม เบอร์เนอรส์ ลี (Tim Berners Lee) ในปัจจุบัน HTML ล่าสุดคือ รุ่น 5 เป็นมาตรฐานหนึ่งของ ISO ซึ่งจัดการโดย World Wide Web Consortium (W3C) ในปัจจุบัน ทาง W3C ผลักดัน รูปแบบของ HTML แบบใหม่ ที่เรียกว่า XHTML รุ่นแรกคือ 1.0 (ม.ค.2543) ซึ่งมีโครงสร้างเป็นแบบ XML (eXtensible Markup Language)
ตัวอย่าง Hello World
ปรับปรุงโปรแกรม source.pl : 2565-07-24
rspsocial
Thaiall.com