รหัสสั้นที่สุดที่จะทำให้เกมต่ำเกินไป - สูงเกินไป


20

คุณต้องสร้างเกมต่ำเกินไป --- สูงเกินไป (TLTH) ในรหัสที่สั้นที่สุด (เป็นไบต์)

กฎของเกม:

  1. คอมพิวเตอร์จะเลือกตัวเลขสุ่มจากช่วงจำนวนเต็ม (-32768 ..32767)
  2. ตอนนี้คุณจะคิดถึงตัวเลขและใส่เข้าไป
  3. คอมพิวเตอร์จะบอกว่าหมายเลขของคุณต่ำกว่า ( TOO LOW) หรือสูงกว่า ( TOO HIGH) มากกว่าหมายเลขที่เลือกหรือไม่
  4. เมื่อคุณเดาหมายเลขคอมพิวเตอร์ควรแสดงCongrats! You found the number!ขึ้น

กฎของรหัส:

  1. อย่าใช้ตัวละครT, O, L, W, H, IและG(ค่าตัวพิมพ์เล็กหรือตัวพิมพ์ใหญ่) ในสตริงหรือตัวอักษรตัวอักษร
    ตัวอย่างเช่น

    tolower(T);  // Acceptable  
    cout<<"T";   // Unacceptable
    char ch='T'; // Unacceptable
    
  2. ลบ 300 ไบต์หากรหัสของคุณสามารถแสดงกฎของเกมก่อนเริ่มเกม

  3. ลบ 50 ไบต์หากรหัสของคุณสามารถนับจำนวนรอบและแสดงจำนวนรอบในตอนท้ายเกมดังนี้:

    "Congrats! You found the number in n turns!"
    

    โดยที่ n คือจำนวนรอบที่ใช้แทน

    "Congrats! You found the number!"  
    
  4. ลบ 25 ไบต์จากคะแนนของคุณหากรหัสของคุณสามารถบอกผู้ใช้ว่าหมายเลขที่คุณป้อนนั้นอยู่นอกช่วงจำนวนเต็ม
    ตัวอย่างเช่น:

    Enter the number: 40000  
    Sorry! This number is out of range
    Please Enter the number again:  
    
  5. ลบ 25 ไบต์หากรหัสของคุณใช้หมายเลขสุ่มไม่ได้มาจากฟังก์ชั่นการสุ่มใด ๆ ในตัว

  6. ลบ 10 ไบต์หากรหัสของคุณแสดงเป็น "แสดงความยินดี" เป็นสี (เลือกสีใดก็ได้ยกเว้นสีขาวเริ่มต้น)

กฎการส่ง:

  1. เพิ่มหัวเรื่องด้วยชื่อภาษาและคะแนนของคุณพร้อมการคำนวณค่าหัวและคำอธิบายทั้งหมด

  2. โพสต์รหัส golfed และ ungolfed ของคุณ

ผู้ชนะ

  1. คำตอบที่มีจำนวนไบต์น้อยที่สุดจะเป็นผู้ชนะ
  2. หากมีการเสมอคำตอบที่มีคะแนนโหวตมากกว่าชนะ
  3. ผู้ชนะจะถูกเลือกหลังจาก 5 วัน

แก้ไข : โปรดแสดงรหัสของคุณ
แก้ไข 2 : คุณสามารถละเว้นกฎ -1 สำหรับกฎ -3 และ 4 ในกฎของรหัส

โชคดีที่สุด:]


2
นี่เป็นคำอธิบายที่ถูกต้องของกฎของเกมหรือไม่ WhileURong(USayNumbr;ISayBigrOrSmalr)
John Dvorak

1
ขึ้นอยู่กับคำอธิบายของการให้คะแนนของคุณคุณไม่มีรหัสกอล์ฟหรือการแข่งขันความนิยม มันเป็นความท้าทายรหัส(พร้อม tiebreaker ความนิยม) ตรวจสอบแท็ก wikis ฉันเสนอการแก้ไขเพื่อแท็กการท้าทายอย่างเหมาะสม ป.ล. - ซวย! @mniip
Jonathan Van Matre

1
@JanathanVanMatre สำหรับฉันถ้อยคำที่ฟังดูเหมือนcode-golfแม้จะมีตัวผูกไทเกอร์
mniip

21
นอกจากนี้ฉันไม่ชอบกฎโดยเฉพาะในการช่วยเหลือผู้เล่นคนอื่นในการปรับปรุงคำตอบของพวกเขา ในคำพูดที่เป็นอมตะของ Andre the Giant ในเจ้าหญิงเจ้าสาว "นั่นไม่เหมือนนักกีฬามาก"
Jonathan Van Matre

1
คำถามนี้เป็นเช่นนั้น . . David H. Ahl
Michael Stern

คำตอบ:


2

จาวาสคริปต์ (-210 คะแนน ( 190ไบต์ - 300 (สำหรับกฎ) - 50 (สำหรับจำนวนการเดา)) - 25 (สำหรับการไม่ใช้แหล่งที่มาของตัวเลขสุ่มแบบบิวด์อิน) - 25 (สำหรับบอกคุณว่าอินพุตอยู่นอกช่วงของลายเซ็นหรือไม่16จำนวนเต็มบิต) ):

แข็งแรงเล่นกอล์ฟ:

alert('Guess number',n=(m=2<<15)/2-new Date%m);for(z=0;a=+prompt(++z);)alert(a>m|a<1-m?m+'-'+-~-m:a==n?'Great! You found the number in '+z+' turns':atob('VE9P\x47E'+(a>n?'hJR0g=':'xPVw==')))

รหัสเต็ม (จัดรูปแบบเป็นอย่างดี):

var max = 2 << 15;
var random = max/2 - new Date%max;
var counter = 0;

while (1) {
    var guess = +prompt();

    ++counter;

    if (guess > max | guess < -~-max) {
        alert(-~-max + '-' + max); // Shows that the range is between -32767 and 32768
    } else if (guess > random) {
        alert('TOO HIGH');
    } else if (guess < random) {
        alert('TOO LOW');
    } else if (guess == random) {
        alert('Congrats! You found the number in ' + counter + ' turns');
        break;
    }
}

เอาท์พุท:

ALERT:  Guess number
PROMPT: 5
ALERT:  TOO LOW
PROMPT: 20000
ALERT:  TOO LOW
PROMPT: 30000
ALERT:  TOO HIGH
PROMPT: 25000
ALERT:  TOO HIGH
PROMPT: 22500
ALERT:  TOO HIGH
PROMPT: 21000
ALERT:  TOO HIGH
PROMPT: 20500
ALERT:  TOO HIGH
PROMPT: 20200
ALERT:  TOO LOW
PROMPT: 20400
ALERT:  TOO LOW
PROMPT: 20450
ALERT:  TOO LOW
PROMPT: 20475
ALERT:  TOO HIGH
PROMPT: 20460
ALERT:  TOO LOW
PROMPT: 20468
ALERT:  TOO HIGH
PROMPT: 20464
ALERT:  TOO LOW
PROMPT: 20466
ALERT:  TOO LOW
PROMPT: 34000
ALERT:  -32767-32768
PROMPT: 20467
ALERT:  Great! You found the number in 17 turns!
PROMPT: (nothing)

@IlmariKaronen ขออภัยฉันทำผิดพลาด ฉันอัพเดตคำตอบแล้ว
แปรงสีฟัน

ขอบคุณตอนนี้ก็ทำงาน ... 0แต่ดูเหมือนว่าจะแตกถ้าฉันเดา :-( นอกจากนี้ไม่ควรมีช่องว่างในTOO LOW/ TOO HIGH?
Ilmari Karonen

19

Perl 5.10+: 159 144 ไบต์ - 350 = −206 คะแนน

say"Guess 16 bit signed number";$==32767-rand 65536;say(TOO.$",$_<0?LOW:HIGH)while++$i,$_=<>-$=;say"Congrats! You found the number in $i turns!"

แก้ไข 2:ด้วยการเปลี่ยนแปลงกฎล่าสุดที่อนุญาตให้ฉันใช้สตริงตัวอักษรใด ๆ สำหรับข้อความ "ขอแสดงความยินดี" ฉันสามารถบันทึก 15 ไบต์จากโซลูชัน 159 ไบต์ดั้งเดิมของฉัน ไม่มีอะไรแปลกใหม่หรือน่าสนใจเกี่ยวกับรหัสใหม่ข้างต้นเมื่อเทียบกับรหัสเก่า (ฉันเพิ่งกำจัดออกไปpฟังก์ชั่นและโทรออกsayโดยตรงแทน) ดังนั้นส่วนที่เหลือของโพสต์นี้จะอธิบายรหัสเดิมดังที่แสดงด้านล่าง:

sub p{say join$",@_}p Guess,16,bit,signed,number;$==32767-rand 65536;p(TOO,$_<0?LOW:HIGH)while++$i,$_=<>-$=;p Congrats."!",You,found,the,number,in,$i,turns."!"

ใช่ฉันกำลังทำบาปนรกนอกกฎ 1. ใครต้องการเงื่อนไขเมื่อคุณมีbarewords ? ;-)

ทำงานด้วยperl -M5.010เพื่อเปิดใช้งาน Perl 5.10+sayคุณลักษณะ (หรือแทนที่ส่วนของpฟังก์ชันด้วยprint join$",@_,$/ค่าใช้จ่ายเพิ่มเติม 5 ไบต์)

คะแนนโบนัส:

  • −300 คะแนน: "แสดงกฎของเกมก่อนเริ่มเกม"
  • −50 คะแนน: "แสดงจำนวนรอบการเลี้ยวในตอนท้ายของเกม"

รหัสไม่มีตัวอักษรสตริงในความหมายที่เข้มงวดดังนั้นฉันจึงบอกว่ากฎ 1 คือในทางเทคนิคไม่ได้ละเมิด เคล็ดลับก็คือใน Perl โดยไม่ต้องuse strictมีตัวระบุใด ๆ ที่ไม่สอดคล้องกับคำหลักภาษาที่รู้จักกันหรือรูทีนย่อยจะง่ายประเมินชื่อของตัวเอง ฟังก์ชั่นpนั้นใช้รายการคำและพิมพ์ออกมาโดยคั่นด้วยช่องว่าง

ตัวอย่างการเล่นผ่าน:

Guess 16 bit signed number
0
TOO HIGH
-10000
TOO LOW
-5000
TOO HIGH
-7500 
TOO LOW
-6250
TOO HIGH
-6875
TOO LOW
-6553
TOO HIGH
-6700
TOO HIGH
-6790
TOO LOW
-6745
TOO HIGH
-6767
TOO LOW
-6756
TOO HIGH
-6761
Congrats! You found the number in 13 turns!

แก้ไข:โอ้ถูกต้องกฎบอกว่าฉันต้องโพสต์โค้ดที่ไม่ตีกอล์ฟเช่นกัน ในทางเทคนิคแล้วมันเป็น "de-golfed" เนื่องจากฉันมักจะเขียนโปรแกรมกอล์ฟของฉันในรูปแบบ golfed มากขึ้นหรือน้อยลงจากจุดเริ่มต้นและบางครั้งมันอาจเป็นเรื่องยากที่จะลบการเพิ่มประสิทธิภาพ "golfy" ทั้งหมดโดยไม่ต้องเปลี่ยนวิธีบางส่วน โปรแกรมทำงาน ยังฉันอย่างน้อยพยายามเพิ่มช่องว่างความคิดเห็นและชื่อฟังก์ชั่น / ตัวแปรที่มีความหมายมากขึ้น:

sub output {
    # print all arguments separated by spaces, plus a newline:
    # (in the golfed code, I use the special variable $" instead of " " for a space)
    say join " ", @_;
}

# print the rules:
output Guess, 16, bit, signed, number;

# choose a random number between -32768 and 32767 inclusive:
# (in the golfed version, using the special variable $= allows
# the int() to be left out, since $= can only take integer values)
$number = int( 32767 - rand 65536 );

# loop until the input equals the chosen number, printing "TOO LOW / HIGH":
# (the loop ends when $diff == 0, since 0 is false in Perl)
output (TOO, $diff < 0 ? LOW : HIGH) while ++$count, $diff = (<> - $number);

# print congratulations, including the loop count:
output Congrats."!", You, found, the, number, in, $count, turns."!";

ps เป็นทางเลือกถ้าเพียงแค่ใช้ barewords แทนสายอักขระที่รู้สึกว่า cheaty เกินไปสำหรับคุณนี่เป็นโซลูชั่นขนาด 182 ไบต์ที่ไม่ใช้ตัวอักษรTOLWHIG แม้แต่ใน barewords (แต่ใช้ในตัวดำเนินการทับศัพท์) มันยังคงได้รับโบนัสเหมือนเดิมรวมคะแนน182 - 350 = −168 คะแนน :

sub t{pop=~y/kpqvxyz/tolwhig/r}say"Guess 16 bit signed number";$==32767-rand 65536;say uc t"kpp ".($_<0?qpv:xyzx)while++$n,$_=<>-$=;say t"Cpnzraks! Ypu fpund kxe number yn $n kurns!"

ผลลัพธ์มีลักษณะเหมือนกับข้างบนทั้งหมด ตามกฎ (ต้นฉบับ) ฉันใช้ตัวอักษรtและiพิมพ์กฎเนื่องจากได้รับอนุญาต แม้ว่าการกำจัดการใช้งานเหล่านั้นจะมีค่าใช้จ่ายเพิ่มสองไบต์เท่านั้น ในทางกลับกันการทำเอาต์พุตตัวพิมพ์ใหญ่ทั้งหมด (ซึ่งอิงตามความคิดเห็นด้านบนดูเหมือนว่าได้รับอนุญาต) จะให้ฉันบันทึกสามไบต์


นั่นคือคำตอบที่ดีและฉลาด! +1 จากฉัน
Mukul Kumar

ตอนนี้ที่ผมเห็นผมสงสัยนี้ถ้ามันอาจจะเป็นจังหวะกับทับทิม 1.8 def method_missing *args;args.join' ';endถ้าคุณใช้การลงโทษสำหรับ
Kaya

ฉันชนะคุณด้วย JavaScript เก่าที่ดี!
แปรงสีฟัน

14

Python 2: -80 คะแนน (270-300-50)

print"WhileURong(USayNumbr;ISayBigrOrSmalr)"
import random
r=random.randint(-32768,32767)
g=i=1
while g:g=cmp(input(),r);print("C\x6fn\x67ra\x74s! Y\x6fu f\x6fund \x74\x68e number \x69n %d \x74urns!"%i,"\x54\x4f\x4f \x48\x49\x47\x48","\x54\x4f\x4f \x4c\x4f\x57")[g];i+=1

คะแนนคือ 270 ตัวอักษรลบ 300 สำหรับการแสดงคำแนะนำลบ 50 สำหรับการแสดงจำนวนการเดาใน "ขอแสดงความยินดี!" สตริงสำหรับจำนวนลบ 80 คะแนน

เวอร์ชันของวงวนที่ไม่ถูกตรึงด้วยสตริงที่ไม่ใช้ Escape:

while g:
    g=cmp(input(),r)
    print ("Congrats! You found the number in %d turns!"%i,
           "TOO HIGH",
           "TOO LOW")[g]
    i+=1

cmpฟังก์ชั่นในตัวส่งกลับ 0 ถ้าค่าเท่ากัน -1 ถ้าแรกมีขนาดเล็กและ 1 ถ้าแรกมีขนาดใหญ่กว่า ฉันใช้ค่าเพื่อจัดทำดัชนี tuple ของสตริงและจากนั้นอีกครั้งเป็นเงื่อนไขทางออกของลูป การทำดัชนีลำดับที่มีดัชนีลบ (เช่น -1) นับจากจุดสิ้นสุดของลำดับแทนที่จะเป็นตั้งแต่เริ่มต้น

ฉันถูกล่อลวงอย่างมากที่จะข้ามการนำเข้าและเพียงใช้4เป็นหมายเลขสุ่มของฉันตามXKCD 221 (นั่นจะมีสิทธิ์ได้รับโบนัสอักขระ -25 หรือไม่)

ตัวอย่าง run (มีข้อผิดพลาดตรงที่ฉันไม่สามารถลบ math ได้):

WhileURong(USayNumbr;ISayBigrOrSmalr)
0
TOO HIGH
-16000
TOO LOW
-8000
TOO HIGH
-12000
TOO HIGH
-14000
TOO LOW
-13000
TOO HIGH
-13500
TOO HIGH
-13750
TOO LOW
-13625
TOO HIGH
-13712
TOO LOW
-13660
TOO HIGH
-13640
TOO HIGH
-13685
TOO HIGH
-13700
TOO LOW
-13695
TOO LOW
-13690
TOO LOW
-13687
Congrats! You found the number in 17 turns!

โปรดแสดงตัวอย่างรหัสของคุณ
Mukul Kumar

2
นี่ไม่ใช่กฎการละเมิดรหัส 1 ใช่หรือไม่ whileURong (USayNumbr; ISayBigrOrSmalr) มีอย่างน้อยหนึ่ง Os, Ls, Ws, Hs, Is และ Gs
Fors

@ Cruncher: ฉันไม่แน่ใจว่าคุณหมายถึงอะไรเพราะโปรแกรมหยุดทำงาน หลังจากที่คุณได้รับค่าที่ถูกต้องgคือศูนย์และwhileวงสิ้นสุด
Blckknght

@ Blckknght อุ๊ปส์อ่านอย่างรวดเร็ว
Cruncher

@ForsYou can ignore Rule-1 for Rules-2,3 & 4 in Code Rules
Cruncher

13

JavaScript 293, -300 (กฎ) - 50 (รอบการแสดงผล) - 25 (คำเตือนช่วง) - 25 (ไม่มีฟังก์ชั่นการสุ่ม) = -107 (คะแนนใหม่)

r=new Date%65536+~(z=32767);n=x="";for((A=alert)("\107uess my number, \111 \147\151ve feedback");(x=prompt())!=r;A(0>(x-~z^x-z)?"\164\157\157 "+(x>r?"\150\151\147\150":"\154\157\167"):"Ran\147e: "+~z+" - "+z))n++;A("C\157n\147ra\164s! Y\157u f\157und \164\150e number \151n "+ ++n+"\164urns!")

ฉันอ้างว่าตามอนุสัญญา RGB ว่าสีดำเป็นสี แต่นั่นก็เป็นการโกง ...

โอ้และฉันอาจจะเพิ่มไม่มีกฎข้อผิดพลาด # 1 อย่างใดอย่างหนึ่ง!

เอาท์พุทในชุดของการแจ้งเตือนและแจ้งให้

ALERT: Guess my number, I give feedback
PROMPT: 0
ALERT: too low
PROMPT: 16000
ALERT: too low
PROMPT: 24000
ALERT: too low
PROMPT: 28000
ALERT: too high
PROMPT: 26000
ALERT: too high
PROMPT: 25000
ALERT: too low
PROMPT: 25500
ALERT: too high
PROMPT: 25250
ALERT: too low
PROMPT: 25375
ALERT: too high
PROMPT: 25310
ALERT: too low
PROMPT: 25342
ALERT: too low
PROMPT: 25358
ALERT: too low
PROMPT: 25366
ALERT: too high
PROMPT: 25362
ALERT: too high
PROMPT: 25360
ALERT: too high
PROMPT: 25359
ALERT: Congrats! You found the number in 16 turns!

รหัสไม่ได้รับการตอบกลับ:

r = (new Date)%65536+~(z=32767); //Generates random number in range based off date's milliseconds... I'd use epoch, but I need to conserve
n=x=""; // Sets count and input to blank, these change as time goes on
// The line below sets up a call for `alert`, provides the initial rules, and subsequent loops compares the prompt with the number, as well as sets up "too", "high",  "low" and "out of range" message strings, and provides the feedback
for((A=alert)("\107uess my number, \111 \147\151ve feedback");(x=prompt())!=r;A(0>(x-~z^x-z)?"\164\157\157 "+(x>r?"\150\151\147\150":"\154\157\167"):"Ran\147e: "+~z+" - "+z))
{
    n++; // adds one to count providing the number isn't guessed yet
}
alert("C\157n\147ra\164s! Y\157u f\157und \164\150e number \151n "+ ++n+" \164urns!") // Congratulates the player, and displays the correct number of turns taken

คุณอ่านกฎอย่างละเอียดหรือไม่ ดีคุณต้องโพสต์รหัส ungolfed กับหนึ่งเอาท์พุท
Mukul Kumar

@MukulKumar จัดเรียง ...
WallyWest

คุณสามารถบันทึก 4 โดย prefixing กับคำตอบของคุณA=alert;และแทนที่ทั้งหมดของด้วยalert Aและอีกหนึ่งถ้าคุณย้ายการแจ้งเตือนหลังจากอัฒภาคในA(0>(x... prompt())!=r;)n++1
DocMax

คุณสามารถเปลี่ยนfeedback if too high/lowที่ใช้ 84 ตัวอักษรในปัจจุบันi give feedback(ซึ่งจะต้องมี\151 \147\151ve feedbackหรือ 24 ตัวอักษรเพื่อประหยัด60 ตัวอักษร .
corsiKa

1
ฉันอาจจะผิด แต่ฉันคิดว่าคุณสามารถย้ายn++จากห่วงสำหรับไปยังx=prompt(n++)เพื่อบันทึกไม่ต้องทำ+ ++n+ในการแจ้งเตือนครั้งสุดท้าย มันจะประหยัด 3
DocMax

7

Javascript, 324 ไบต์, คะแนน -76

[อัปเดตเนื่องจากการเปลี่ยนแปลงกฎ]

  • 324 ไบต์
  • -300 สำหรับการแสดงกฎ
  • -50 เพื่อแสดงการเลี้ยวเมื่อผู้ใช้ชนะ
  • -25 สำหรับบอกผู้ใช้เมื่อเขาป้อนตัวเลขที่อยู่นอกช่วง
  • -25 สำหรับการไม่ใช้งานแบบสุ่มในตัว (อัพเดท)

คะแนนรวม: -76

แข็งแรงเล่นกอล์ฟ:

function q(y){return y.replace(/./g,function(x){h=x.charCodeAt(0);return String.fromCharCode(h>32&h<58?h+32:h)})}d=o=32768;alert("WhileURong(USayNumbr;ISayBigrOrSmalr)");for(a=1,n=new Date%(2*o)-o;d-n;a++)d=+prompt(a),alert(d>=o|d<-o?"BAD":d<n?q("4// ,/7"):d>n?q("4// ()'("):"Congrats! You found the number in "+a+" turns!")

ปล่อยให้ความโกลาหลวุ่นวายนี้

ขั้นแรกให้ระบุอย่างถูกต้อง (แต่นี่ยังไม่ดีกับรหัสที่สับสน):

function q(y) {
  return y.replace(/./g, function(x) {
    h = x.charCodeAt(0);
    return String.fromCharCode(h > 32 & h < 58 ? h + 32 : h)
  })
}

d = o = 32768;
alert("WhileURong(USayNumbr;ISayBigrOrSmalr)");

for (a = 1, n = new Date % (2 * o) - o; d - n; a++)
  d = +prompt(), alert(d >= o | d < -o ? "BAD" : d < n ? q("4// ,/7") : d > n ? q("4// ()'(") : "Congrats! You found the number in " + a + " turns!")

ประการที่สองการเปลี่ยนชื่อตัวระบุ:

function unencrypt(encrypted) {
  return encrypted.replace(/./g, function(character) {
    charCode = character.charCodeAt(0);
    return String.fromCharCode(charCode > 32 & charCode < 58 ? charCode + 32 : charCode)
  })
}

guess = limit = 32768;
alert("WhileURong(USayNumbr;ISayBigrOrSmalr)");

for (tries = 1, randomNumber = new Date % (2 * o) - o; guess - randomNumber; tries++)
  guess = +prompt(),
  alert(guess >= limit | guess < -limit ? "BAD" : guess < randomNumber ? unencrypt("4// ,/7") : guess > randomNumber ? q("4// ()'(") : "Congrats! You found the number in " + tries + " turns!")

ดังนั้นฟังก์ชั่น unencrypt จะได้รับอักขระทั้งหมดระหว่าง ASCII 33 ( !) และ ASCII 58 ( :) และเพิ่ม 32 โดยแปลงเป็นอักขระในช่วงA-Zแปลงพวกเขาในตัวละครในช่วง

ให้ ungolf โค้ดมากขึ้นโดยการถอดรหัสสตริงทั้งหมด:

guess = limit = 32768;
alert("WhileURong(USayNumbr;ISayBigrOrSmalr)");

for (tries = 1, randomNumber = new Date % (2 * o) - o; guess - randomNumber; tries++)
  guess = +prompt(),
  alert(guess >= limit | guess < -limit ? "BAD" : guess < randomNumber ? "TOO LOW" : guess > randomNumber ? "TOO HIGH" : "Congrats! You found the number in " + tries + " turns!")

และสุดท้ายให้ย้ายคำแนะนำไปยังที่อื่น ๆ แทนที่โซ่ที่ประกอบไปด้วยโซ่ยาวด้วย ifs และ elses เข้าร่วมสตริงที่ต่อกันและทำให้คณิตศาสตร์ง่ายขึ้นเพื่อเพิ่มความสามารถในการอ่าน:

guess = 32768;
alert("WhileURong(USayNumbr;ISayBigrOrSmalr)");

randomNumber = new Date % 65536 - 32768;

for (tries = 1; guess - randomNumber; tries++) {
  guess = +prompt(); // The preceding + is a golfing trick to convert string to number.
  if (guess > 32767 | guess < -32768) {
    alert("BAD");
  } else if (guess < randomNumber) {
    alert("TOO LOW");
  } else if (guess > randomNumber) {
    alert("TOO HIGH");
  } else {
    alert("Congrats! You found the number in " + tries + " turns!");
  }
}

ตัวอย่าง:

ALERT:  WhileURong(USayNumbr;ISayBigrOrSmalr)
PROMPT: 5
ALERT:  TOO LOW
PROMPT: 20000
ALERT:  TOO LOW
PROMPT: 30000
ALERT:  TOO HIGH
PROMPT: 25000
ALERT:  TOO HIGH
PROMPT: 22500
ALERT:  TOO HIGH
PROMPT: 21000
ALERT:  TOO HIGH
PROMPT: 20500
ALERT:  TOO HIGH
PROMPT: 20200
ALERT:  TOO LOW
PROMPT: 20400
ALERT:  TOO LOW
PROMPT: 20450
ALERT:  TOO LOW
PROMPT: 20475
ALERT:  TOO HIGH
PROMPT: 20460
ALERT:  TOO LOW
PROMPT: 20468
ALERT:  TOO HIGH
PROMPT: 20464
ALERT:  TOO LOW
PROMPT: 20466
ALERT:  TOO LOW
PROMPT: 20467
ALERT:  Congrats! You found the number in 16 turns!"

1
ฉันชอบมันมาก :)
Wolle Vanillebär Lutz

โปรดแสดงตัวอย่างรหัสของคุณ
Mukul Kumar

@MukulKumar เสร็จสิ้นการส่งออกเพิ่ม
Victor Stafusa

7

C - 272 ตัวอักษร - 300 - 50 - 25 = -103

  • -300 สำหรับการแสดงกฎ;
  • -50 สำหรับการบอกผู้เล่นถึงจำนวนรอบ
  • -25 สำหรับการไม่ใช้ไลบรารี RNG มาตรฐาน

รหัส Golfed:

main(i){short a,c=i=0,b=time(0);for(a=b;b--;a=(a*233)+4594);b=a;puts("WhileURong(USayNumbr;ISayBigrOrSmalr)");while(1){i++;scanf("%hi",&a);if(a==b){printf("Congrats! You found the number in %i turns!",i);break;}for(c=0;c^9;c++)putchar(c[a<b?"kff7cfn7!":"kff7_`^_!"]-23);}}

Ungolfed:

int main(int i) {
    short a,
          b = time(0),
          c = i = 0;

    for( a = b ; b-- ; a = (a * 233) + 4594);
    b = a;

    puts("WhileURong(USayNumbr;ISayBigrOrSmalr)");

    while(1) {
        i++;
        scanf("%hi", &a);
        if(a == b) {
            printf("Congrats! You found the number in %i turns!", i);
            break;
        }
        for( c = 0 ; c ^ 9 ; c++ )
            putchar(c[ a < b ? "kff7cfn7!" : "kff7_`^_!" ] - 23);
    }
}

เอาท์พุท:

เอาท์พุต


ผลผลิตอยู่ที่ไหน
Mukul Kumar

@IlmariKaronen, EDIT2 นอกจากนี้ฉันไม่เพียงแค่นำยุค
Oberon

@Oberon โปรดโพสต์ผลลัพธ์ด้วย
Mukul Kumar

@MukulKumar, โพสต์แล้ว
Oberon

5

C: 237 - 300 - 50 - 25 - 25 - 10: -173 คะแนน

-300 สำหรับกฎ -50 สำหรับการแสดงจำนวนการเดา -25 สำหรับการไม่ใช้ตัวสร้างตัวเลขแบบสุ่มใด ๆ ในตัว -25 สำหรับข้อความนอกช่วงและ -10 สำหรับการระบายสีข้อความแสดงความยินดี

int s[3]={542068564},g,n;main(r){for(r=(short)&r,puts("WhileURong(USayNumbr;ISayBigrOrSmalr)");n++,scanf("%d",&g),s[1]=g<r?5721932:1212631368,g^r;puts(g^(short)g?"OOR":s));printf("\033[31mCongrats! You found the number in %d turns!",n);}

Ungolfed:

int s[3]={542068564},g,n;

main(r){
        for(
                r=(short)&r,
                puts("WhileURong(USayNumbr;ISayBigrOrSmalr)");

                n++,
                scanf("%d",&g),
                s[1]=g<r?5721932:1212631368,
                g^r;

                puts(g^(short)g?"OOR":s)
        );

        printf("\033[31mCongrats! You found the number in %d turns!",n);
}

ตัวอย่างการเรียกใช้:

WhileURong(USayNumbr;ISayBigrOrSmalr)
-32769
OOR
32768
OOR
0
TOO HIGH
-16384
TOO HIGH
-24576
TOO HIGH
-28672
TOO LOW
-26624
TOO LOW
-25600
TOO HIGH
-26112
TOO LOW
-25856
TOO LOW
-25728
TOO LOW
-25664
TOO HIGH
-25696
TOO HIGH
-25712
TOO LOW
-25704
Congrats! You found the number in 15 turns!

บรรทัดสุดท้ายแสดงเป็นสีแดง


ไชโย! คุณตีเงินทั้งหมด !!!
Mukul Kumar

4

ทุบตี -137

คะแนน

273 (ไบต์) - 300 (กฎ) - 50 (ลองนับ) - 25 (คำเตือน OOF) - 25 (กำหนดเอง PRNG) - 10 (สี)

รุ่น Golfed

IFS=# a=(`<$0`)
c=65536
y=$[10#`date +%N`%c]
e(){ echo -e ${a[$1]/z/$z};}
e 7
while read x
do((z++,x+=c/2,i=3+(x>y),x==y))&&break
((x<0||x>c-1))&&i=6
e $i
done
e 5
#TOO LOW#TOO HIGH#\e[32mCongrats! You found the number in z turns!#OOR#Guess my number. I'll say HIGH or LOW.

โปรดทราบว่าบรรทัดสุดท้ายคือความคิดเห็นดังนั้นจึงไม่มีสตริงหรือตัวอักษร

เวอร์ชันที่ไม่ดี

MYNUMBER=$[10#$(date +%N) % 65536 - 32768]
echo "Guess my number. I'll say HIGH or LOW."

while true; do
    read YOURGUESS
    GUESSES=$((GUESSES + 1))

    if ((YOURGUESS == MYNUMBER)); then
        break
    elif ((YOURGUESS < -32768 || YOURGUESS > 32767)); then
        echo OOR
    elif ((YOURGUESS < MYNUMBER)); then
        echo "TOO LOW"
    else
        echo "TOO HIGH"
    fi
done

echo -e "\e[32mYou found the number in $GUESSES turns!"

ตัวอย่างผลลัพธ์

$ ./tlth
Guess my number. I'll say HIGH or LOW.
-32769
OOR
32768
OOR
0
TOO LOW
16384
TOO HIGH
8192
TOO HIGH
4096
TOO HIGH
2048
TOO HIGH
1024
TOO HIGH
512
TOO HIGH
256
TOO HIGH
128
TOO HIGH
64
TOO HIGH
32
TOO LOW
48
TOO HIGH
40
TOO LOW
44
TOO HIGH
42
Congrats! You found the number in 17 turns!

บรรทัดสุดท้ายพิมพ์เป็นสีเขียว


3

C #: -30 คะแนน

  • 345 ไบต์
  • -300 สำหรับการแสดงกฎ
  • -50 เพื่อแสดงการเลี้ยวเมื่อผู้ใช้ชนะ
  • -25 สำหรับบอกผู้ใช้เมื่อเขาป้อนตัวเลขที่อยู่นอกช่วง

Golfed :

int l=-32768,h=32767,n=new Random().Next(l,h),t=0,g=h+1;Console.Write("WhileURong(USayNumbr;ISayBigrOrSmalr)\n");while(n!=g){g=Convert.ToInt32(Console.ReadLine());Console.WriteLine(g==n?"C\x6fn\x67ra\x74s! Y\x6fu f\x6fund \x74\x68\x65 number in {0} \x74urns!":g<l||g>h?"BAD":g<n?"\x54\x4f\x4f \x4c\x4f\x57":"\x54\x4f\x4f \x48\x49\x47\x48",++t);}

หากต้องการเรียกใช้ให้วางลงในไฟล์ (code.cs) แล้วรันด้วยscriptcsบนบรรทัดคำสั่ง:scriptcs code.csในบรรทัดคำสั่ง:

Ungolfed : ขยายชื่อตัวแปรเป็นสิ่งที่เข้าใจง่ายขึ้นและเปลี่ยนตัวอักษรฐานสิบหกเป็นตัวอักษรจริง

int low = -32768, 
    high = 32767, 
    number = new Random().Next(low, high), 
    turns = 0, 
    guess = h+1;
Console.Write("WhileURong(USayNumbr;ISayBigrOrSmalr)\n");  // instructions
while (number != guess)
{
    guess = Convert.ToInt32(Console.ReadLine());
    Console.WriteLine(
      guess == number                                     // if you got it right 
        ? "Congrats! You found the number in {0} turns!"  // give the victory speech
        : guess < low || guess > high                     // if out of range
          ? "BAD"                                         // let them know
          : guess < number                                // if guess is low
            ? "TOO LOW"                                   // tell them low
            : "TOO HIGH"                                  // otherwise tell them high
      , ++turns                                           // preincrement turns, add to output
    );
}

การแสดงผลตัวอย่างที่นี่


3
ขออภัยที่บอกนี้ แต่รัฐกฎที่ว่า " อย่าใช้ตัวละครT, O, L, W, H, IและG(ค่าตัวพิมพ์เล็กหรือตัวพิมพ์ใหญ่) ในสตริงหรือตัวอักษรตัวอักษร. "
วิคเตอร์ Stafusa

ดังนั้นเพียงแค่เปลี่ยนT, O, L... มี\x54, \x4F, \x4C... และคุณกำลังดี
เฉื่อยชา

ขอบคุณ ฉันใส่การเข้ารหัสเลขฐานสิบหกสำหรับตัวอักษรที่ใช้บังคับในตัวอักษรสตริงในเวอร์ชัน golfed และแก้ไขการให้คะแนนตามนั้น
Yaakov Ellis

โปรดแสดงตัวอย่างรหัสของคุณ
Mukul Kumar

@MukulKumar ดูที่นี่สำหรับการส่งออก ฉันเพิ่งเปลี่ยนแปลงตรรกะเล็กน้อยเพื่อแก้ไขปัญหา
Yaakov Ellis

2

C ++ 505 + (-300-50-25-25) = 105

-300: คำแนะนำ
-50: แสดงจำนวนรอบ
-25: ไม่ได้ใช้ฟังก์ชั่นแบบสุ่ม
-25: เตือนผู้ใช้เกี่ยวกับอินพุตนอกระยะ

แข็งแรงเล่นกอล์ฟ

#include<iostream>
#include<stdlib.h>
using namespace std;int main(){short int a,i=0,*r=new short int;int b=0;a=*r;char t[]={84,79,79,' ','\0'},l[]={76,79,87,'\n','\0'},h[]={72,73,71,72,'\n','\0'};cout<<"WhileURong(USayNumbr;ISayBigrOrSmalr)\n";while(a!=b){cin>>b;if(b<-32768||b>32767){cout<<"Sorry! the number is out of range please enter the number again\n";continue;}i++;if(b<a){cout<<'\n'<<t<<l;}if(b>a){cout<<'\n'<<t<<h;}if(a==b){cout<<"Congrats!You found the number in "<<i<<" turns!";}}return 0;}  

UNGOLFED

#include<iostream>
#include<stdlib.h>
using namespace std;
int main()
{
    short int a,i=0,*r=new short int;
    int b=0;
    a=*r;
    char t[]={84,79,79,' ','\0'},l[]={76,79,87,'\n','\0'},h[]={72,73,71,72,'\n','\0'};
    cout<<"WhileURong(USayNumbr;ISayBigrOrSmalr)\n";
    while(a!=b)
    {
        cin>>b;
        if(b<-32768||b>32767)
        {
            cout<<"Sorry! the number is out of range please enter the number again\n";
            continue;
        }
        i++;
        if(b<a)
        {
            cout<<'\n'<<t<<l;
        }
        if(b>a)
        {
        cout<<'\n'<<t<<h;
        }
    if( a==b)
    {   

            cout<<"Congrats!You found the number in "<<i<<" turns!";
        }
    }
    return 0;
}  

เอาท์พุท


โดยส่วนตัวแล้วฉันไม่สามารถหยุดตัวเอง .. :)
Mukul Kumar

2

C, 183-300-25 = -142

183 ไบต์ -300 สำหรับกฎ -25 สำหรับการไม่ใช้ไลบรารีแบบสุ่ม

main(){short g,n=time(0)*(time(0)&1?1:-1);puts("WhileURong(USayNumbr;ISayBigrOrSmalr)");while(g^n)scanf("%d",&g),puts(g>n?"TOO HIGH":g<n?"TOO LOW":"Congrats! You found the number!");}

เวอร์ชันที่ไม่ถูกปรับแต่ง:

main(){
    short g,n=time(0)*(time(0)&1?:-1);
    puts("WhileURong(USayNumbr;ISayBigrOrSmalr)");
    while(g^n)
        scanf("%d",&g),
        puts(g>n?"TOO HIGH":g<n?"TOO LOW":"Congrats! You found the number!");
}

วิ่งตัวอย่าง:

WhileURong(USayNumbr;ISayBigrOrSmalr)
40
TOO HIGH
20
TOO HIGH
1
TOO HIGH
0
TOO HIGH
-20
TOO HIGH
-200
TOO HIGH
-2000
TOO HIGH
-20000
TOO LOW
-10000
TOO LOW
-5000
TOO LOW
-3000
TOO HIGH
-4000
TOO LOW
-3500
TOO HIGH
-3700
TOO HIGH
-3900
TOO HIGH
-3950
TOO HIGH
-3970
TOO LOW
-3960
Congrats! You found the number!

"TOO HIGH"และทั้งสองมีตัวละครที่ผิดกฎหมาย"TOO LOW" TOLWHIGtolwhig
Oberon

"ยินดีด้วย! คุณพบเบอร์!" และ "WhileURong (USayNumbr; ISayBigrOrSmalr)"
Fors

@Fors แต่ได้รับอนุญาต (ดูEDIT2 )
Oberon

แน่นอนพวกเขาเป็น! ด้วยเหตุผลบางอย่างฉันพลาดการแก้ไข
Fors

@Oberon TOO LOWอนุญาตให้แก้ไขได้ 2เช่นกัน?
แปรงสีฟัน

2

J - 190 char -300 -50 = -160 pts

'Congrats, you found the number in ',' turns!',~":1>:@]^:(]`(1[2:1!:2~a.{~71+13 8 8 _39,(5 8 16;1 2 0 1){::~0&>)@.*@-[:".1!:1@1:)^:_~32767-?2^16['WhileURong(USayNumbr;ISayBigrOrSmalr)'1!:2]2

คำอธิบาย (จำไว้ว่า J อ่านจากขวาไปซ้าย):

  • 'WhileURong(USayNumbr;ISayBigrOrSmalr)'1!:2]2 - พิมพ์กฎ
  • 32767-?2^16[- โยนค่าส่งคืนจากนั้นสร้างตัวเลขสุ่มระหว่าง 0 ถึง 2 ^ 16-1 จากนั้นปรับเป็นช่วง -32768 ..32767 โดยลบออกจาก 32767
  • 1>:@]^:(...)^:_~- x u^:v^:_ yแพทเทิร์นเป็นแบบคล้ายห่วง xอยู่อย่างต่อเนื่องและได้รับการกลายพันธุ์ด้วยการดำเนินการทุกy uนี้ต่อไปจนกว่าทั้งx v yผลตอบแทน 0 หรือผลในการเปลี่ยนแปลงใดx u yyการ~แลกเปลี่ยนทั้งสองข้อโต้แย้งเพื่อที่xจะเป็นจำนวนสุ่มและyจะเริ่มต้นที่ 1 ของเราuคือ>:@]ซึ่งเพิ่มขึ้น 1 นี้และส่งกลับมันจึงทำหน้าที่เป็นเคาน์เตอร์และx u yเงื่อนไขการยกเลิกไม่เคยเกิดขึ้น
  • [:".1!:1@1:- ใช้ตัวนับและละเว้นค่าโดยใช้หมายเลข 1 แทน ( 1:) อ่านในบรรทัดอินพุต ( 1!:1) จากแป้นพิมพ์ (ตัวจัดการไฟล์ 1) และดำเนินการ ( ".) สิ่งนี้อนุญาตให้ J ซึ่งโดยปกติสัญญาณลบเป็น_ตัวเลขที่จะนำไปใช้ในแบบฟอร์ม-n(ประเมินว่าเป็นการปฏิเสธที่ใช้กับตัวเลขn )
  • ]`(...)@.*@-- รับความแตกต่างของตัวเลขสุ่มจากก่อนและเดา ( -) ตอนนี้เราเลือกการกระทำถัดไปขึ้นอยู่กับว่าความแตกต่างนี้เป็นศูนย์ ( @.*) ถ้าเป็นเช่นนั้น return ( ]`) คือ 0 เป็นผลลัพธ์เพื่อx v yให้การดำเนินการสิ้นสุดลงและทั้งหมดในขณะที่ loop ส่งคืนตัวนับ อื่น...
  • 71+13 8 8 _39,(5 8 16;1 2 0 1){::~0&>- ส่งกลับอาร์เรย์5 8 16ถ้าจำนวนเป็นลบและ1 2 0 1ถ้ามันเป็นบวก จากนั้น13 8 8 _39เติมและเพิ่ม 71 ลงในทุกสิ่งดังนั้นเราจึงมี84 79 79 32 76 79 87หรือ84 79 79 32 72 73 71 72หรือ
  • 1[2:1!:2~a.{~- เปลี่ยนตัวเลขเหล่านี้เป็นอักขระ ASCII โดยการจัดทำดัชนีตัวอักษรa.กับพวกเขา แล้วพิมพ์ออกมาด้วย1!:2(โดยใช้ไฟล์จับ 2) และกลับ 1 x v yเป็นผลมาจากการ
  • 'Congrats, you found the number in ',' turns!',~":- เมื่อลูปเสร็จสิ้นจะส่งคืนตัวนับ แปลงเป็นสตริงด้วย":และวางไว้ในระหว่างสตริงและ'Congrats, you found the number in '' turns!'

ตัวอย่างผลลัพธ์:

   'Congrats, you found the number in ',' turns!',~":1>:@]^:(]`(1[2:1!:2~a.{~71+13 8 8 _39,(5 8 16;1 2 0 1){::~0&>)@.*@-[:".1!:1@1:)^:_~32767-?2^16['WhileURong(USayNumbr;ISayBigrOrSmalr)'1!:2]2
WhileURong(USayNumbr;ISayBigrOrSmalr)
0
TOO HIGH
-20000
TOO LOW
-10000
TOO LOW
-5000
TOO HIGH
-7500
TOO HIGH
-8750
TOO HIGH
-9000
TOO HIGH
-9500
TOO LOW
-9250
TOO HIGH
-9375
TOO HIGH
-9450
TOO LOW
-9400
TOO HIGH
-9425
TOO HIGH
-9437
TOO LOW
-9431
TOO LOW
-9428
TOO HIGH
-9430
TOO LOW
-9429
Congrats, you found the number in 18 turns!

2

JavaScript -40

335 - 300 (กฎ) - 50 (นับรอบ) - 25 (นอกช่วง)

ไม่ใช่ว่าจะชนะ แต่เป็นวิธีที่สนุกในการรับตัวอักษรที่ฉันคิด

แข็งแรงเล่นกอล์ฟ

!function T(O,L,W,H,I,G){a=T.toString();c=L.floor(65536*L.random())+H;O(W+G+" between "+H+" & "+I);k=(f=a[9]+(d=a[11])+d+" ")+(e=a[17])+a[19]+a[21]+e;l=f+a[13]+d+a[15];for(m=1;(n=prompt(W+G))!=c;m++)n<H||n>I?O("Out of range"):n>c?O(l):O(k);O("Congrats! You found the"+G+" in "+m+" turns!")}(alert,Math,"Guess a",-32768,32767," number")

Ungolfed

!function T(O,L,W,H,I,G){
    fn = T.toString();
    random = L.floor(L.random() * 65536) + H;

    O(W + G + " between " + H + " & " + I);

    tooLow = (too = fn[9] + (o = fn[11]) + o + " ") + (h = fn[17]) + fn[19] + fn[21] + h;
    tooHigh = too + fn[13] + o + fn[15];

    for (n=1; (guess = prompt(W + G)) != random; n++) {
        if (guess < H || guess > I) {
            O("Out of range");  
        } else if (guess > random) {
            O(tooHigh);
        } else {
            O(tooLow);  
        }
    }

    O("Congrats! You found the" + G + " in " + n + " turns!");
}(alert, Math, "Guess a", -32768, 32767, " number")

ตัวอย่างผลลัพธ์

(ALERT) Guess a number between -32768 & 32767
(PROMPT) Guess a number
9999999
(ALERT) Out of range
(PROMPT) Guess a number
0
(ALERT) TOO LOW
(PROMPT) Guess a number
8008
(ALERT) Congrats! You found the number in 3 turns!

1

APL (Dyalog) (157 - 300 - 50 = -193)

(ใช่นับเป็นไบต์ตัวอักษร APL เหมาะกับไบต์)

ฉันอ้างว่า "แสดงกฎของเกม" และ "นับจำนวนรอบ"

G
n←32768-?65536
t←0
⎕←'Guess 16-bit signed number'
t+←1
→8/⍨n=g←⎕
⎕←⎕AV[(⌽⎕AV)⍳'×↑↑ ','○↑-' '∇⌊∘∇'⊃⍨1+n<g]
→4
⎕←'Congrats! You found the number in't'tries!'

ตัวอย่างการเรียกใช้:

      G
Guess 16-bit signed number
⎕:
      0
TOO HIGH
⎕:
      -10000
TOO LOW
⎕:
      -5000
TOO LOW
⎕:
      -2500
TOO LOW
⎕:
      -1250
TOO HIGH
⎕:
      -1750
TOO LOW
⎕:
      -1500
TOO LOW
⎕:
      -1375
TOO LOW
⎕:
      -1300
TOO LOW
⎕:
      -1275
TOO LOW
⎕:
      -1265
TOO HIGH
⎕:
      -1270
TOO HIGH
⎕:
      -1273
 Congrats! You found the number in  13  tries!

Ungolfed:

GuessNumber;num;tries;guess;decode;too;low;high
decode←{⎕AV[(⌽⎕AV)⍳⍵]} ⍝ invert the character code, char 1 becomes char 255 etc.
num←32768-?65536 ⍝ select a random number
tries←0

⍝ strings for low/high
too←decode '×↑↑ '
low←decode '○↑-'
high←decode '∇⌊∘∇'

⎕←'Guess 16-bit signed number'

try:
  tries +← 1
  guess ← ⎕
  →(guess=num)/found
  ⍝ still here: number was wrong
  ⎕←too, (1+num<guess)⊃low high  ⍝ output appropriate word
  →try ⍝ try again
found:
  ⎕←'Congrats! You found the number in' tries 'tries!'

1

Pogo: -95 (255 - 300 - 50)

method main:void
    print("Guess the number. You will be told if you are high or low.")
    declare(integer,n,0)
    declare(integer,i,0)
    declare(integer,j,0)
    random() i
    while j != i
        set(n+1) n
        print("Number?")
        getinput() j
        if j > i
            print("High")
        end
        else
            print("Low")
        end
    end
    print("Yay" n "turns")
end main

ถ้าตัวเลขคือ 10:

จำนวน?

5

ต่ำ

8

ต่ำ

12

สูง

10

Yay 4 รอบ


จำนวนตัวละครจะขึ้นอยู่กับรหัสที่มีการลบช่องว่างทั้งหมด

โปรดทราบว่า Pogo ไม่ใช่ภาษาปลอม ฉันสร้างและเขียนคอมไพเลอร์และ IDE ที่นี่: https://github.com/nrubin29/Pogo


อ่านการแก้ไขและการแก้ไขของฉัน- 2
Mukul Kumar

อัปเดตตามการแก้ไข
nrubin29
โดยการใช้ไซต์ของเรา หมายความว่าคุณได้อ่านและทำความเข้าใจนโยบายคุกกี้และนโยบายความเป็นส่วนตัวของเราแล้ว
Licensed under cc by-sa 3.0 with attribution required.