The Great British Cake Off

21

Saya mendengar seseorang sangat egois pada hari ulang tahun mereka, meminta kue dari semua orang dan tidak ada rencana untuk dibagikan! 🎂

Ini pasti hari ulang tahun seseorang, jadi mengapa tidak membuatkan kue untuk mereka. Gunakan bahasa pemrograman favorit Anda untuk membuat kue yang lezat, dengan pesan "Selamat Ulang Tahun" yang bagus sebagai hasilnya. (Mungkin saya sarankan Chef !)

Kue Anda harus

  • Meniru resep dunia nyata (jika Anda dapat menautkannya, brilian!)
    • daftar bahan terpisah baris baru yang cocok untuk membuat kue
    • daftar langkah-langkah untuk metode yang dipisahkan baris baru
    • berapa banyak orang yang dilayaninya
  • Tetap sedekat mungkin dengan rasio bahan yang tepat.
  • Keluarkan minimal "Selamat Ulang Tahun" saat disajikan.

Kue terbaik adalah:

  • Enak - karena ini adalah , komunitas akan memutuskan apa yang enak
  • Dipersonalisasi - cobalah membuat pesan selamat ulang tahun khusus untuk orang tertentu. (Jika Anda tidak dapat menemukan pengguna PPGC, mengapa tidak menjadi selebriti?)
  • Seimbang - Cobalah menggunakan jumlah bahan yang cocok untuk jumlah porsi yang disiapkan resep. 1000 eggs, serves 1untuk satu porsi mungkin hanya sedikit amat besar , besar ,

    benar-benar kolosal!

  • Outlandish - Anda dapat memanggang lebih dari sekedar spons dasar, misalnya, termasuk beberapa lapisan gula, gerimis, sajikan dengan saus, dekorasi, dll.
  • Menarik secara visual - gambar baik dalam kode sumber ascii atau dalam output. "Byte" pertama adalah dengan mata.

Dan jangan lupa, tukang roti yang baik tidak mengambil jalan pintas dan melakukan hal-hal dengan benar. ( Jangan hanya menggunakan kode tidak-op agar terlihat seperti resep lalu cetak, pastikan kode Anda berarti sesuatu ) Saya mendorong pemilih untuk melihat resep ini secara negatif.

Selamat Kue!

masukkan deskripsi gambar di sini

James Webster
sumber
3
Hei, dalam pembelaanku, kupikir kalian semua akan membelikanku beberapa!
Beta Decay
Apakah ada penghiburan yang saya khawatirkan bahwa Anda akan kesal ?
James Webster
Nah tidak apa-apa, saya hanya bercanda;)
Beta Decay
Mungkin seharusnya juga curang ?
Vi.
@close voter: Saya mencantumkan 3 kriteria yang harus dipenuhi semua program dan 6 kriteria yang "hakim" dapat gunakan untuk memilih kue. Apa yang saya lewatkan?
James Webster

Jawaban:

21

ECMAScript 2015, melayani 10

Don  =([_])=> alert(_.replace(/^.*(?=, )/,'Happy Birthday'))

ReadMoreAbout  =classic=  victoria  =sandwich=  on  =bbcgoodfood=      ~`

âš   Remember that OCR technologies aren't perfect, and that scanning old,
âš   smudgy recipes does not always go as smoothly as we'd expect or hope.
âš   This recipe is not wonderful, but please, thoroughly enjoy making it.

`

try/* to do this properly! */{
  // Link to recipe:
  bbcgoodfood.com/recipes/1997/classic-victoria-sandwich
  'Makes 10 slices'

  Ingredients:
    ForThecake:
      - 200 | grammes | castorSugar
      - 200 | grammes | softenedButter
      -   4 | whole   | eggs
      - 200 | grammes | self-raising_flour
      -   1 | tsp     | bakingPowder
      -   2 | tbsp    | milk

    For_theFilling:
      -  100 | grammes | butter, softened
      -  140 | grammes | icing.sugar, sifted
      -    a | drop    | vanilla- extract (optional)
      -  240 | grammes | jar.good-quality_strawberryJam
      -                  icingSugar, to.decorate

  Method:
    1. ^`Heat oven to 190C/fan 170C/gas 5. Butter two 20cm sandwich tins
         and line with non-stick baking paper. In a large bowl,
         beat all the cake ingredients together until you have a smooth, soft batter.`
    2. ^`Divide the mixture between the tins, smooth the surface with a spatula
         or the back of a spoon, then bake for about 20 mins until golden
         and the cake springs back when pressed. Turn onto a cooling rack
         and leave to cool completely.`
    3. ^`To make the filling, beat the butter until smooth and creamy,
         then gradually beat in icing sugar. Beat in vanilla extract if you’re
         using it. Spread the butter cream over the bottom of one of the sponges,
         top it with jam and sandwich the second sponge on top.
         Dust with a little icing sugar before serving.
         Keep in an airtight container and eat within 2 days.`

  * HappyBirthdayǃ
} catch (cake) {
  Don`t drop that! It's your cake, Uncle Chris! This cake is one day late – sorry about that.
`}

Kode ES6 yang valid; tidak ada sudut terpotong!

Ini berfungsi di Firefox Developer Edition.

Itu semua kode yang valid; trysatu - satunya berfungsi untuk menangkap yang ReferenceErrordisebabkan oleh variabel yang tidak didefinisikan.

Sikat gigi
sumber
Ini jawaban yang bagus. Ini yang saya cari. 😆
James Webster
5
Jelas âš  harus menjadi karakter komentar yang valid dalam ECMAScript 7.
user253751
@immibis Ya, pasti :-)
Sikat gigi
23

BF

Terinspirasi oleh jawaban mbomb007s, saya membuatkannya kue.

Saya khawatir saya kehilangan resep (ada di sekitar sini, tapi saya mungkin harus melanggar aturan saya sendiri tentang memotong sudut untuk mempostingnya); di sini adalah produk jadi.

                                    +
                                    [
                       (
               )                    )             (
                       )           (o)    )
               (      (o)    )     ,|,            )
              (o)     ,|,          |~\    (      (o)
              ,|,     |~\    (     \ |   (o)     ,|,
              \~|     \ |----(o)->++|+\<]>,|,     |+.
              |`\-----|`\@@@-|-@@@@\.-@@@\~|[++>-\ |-
             -\-|-o@@@\ |@@@<]>@@@@|.\@@@|.\@@@o+|+\++
            ++|+\@@@@@|+\@@@|+\@@@@\.|@@@\-[@@@@@\-|o-- 
           ->@\+|@@@@@\<|@@@]>|@@@@@@@@@@|+\@@@@@|+\@@o.
          [->+|+\+@@@@@@@@@@|<]@@@@@@@@@@\>|@@@@@\+|+@@@.
          +@@@@@@@@@@@@@@@@@\+|@@@@@@@@@@|+\@@@@@@@@++++.
          @@++@@@@@@@@@@@@@@|+\@@@@@@@@@@@@@@@@@@@@+++++
          +.@@@++@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@o@@.-@
          --@@--@@-@@@@@@@@@@@@@@@@@@@@@@@@@@@@-@@-@@--@
          --@@.-@@@@---.@@@@--@@@@@-.+[@@@@@o---@@@>+<:]
          >::::::+::::::++@@.::@@@:::::@@@@:::::@@:::::%
          %%::::::::::::@@::::::@:::::::@@::::::::::::%%
          ::%%%::::::::::@::::::::::::::@::::::::::%%%::
       º# ::%::%%%%%%:::::::::::::::::::::::::%%%%%::%::##º
     º### ::::::%%:::%:%%%%%%%%%%%%%%%%%%%%%:%:::%%::::: ###º
   º##### ::::::%:::::%%::::::%%%%:::::%%::::%:::::::::: #####º
  º###### `:::::::::::%:::::::%:::::::::%::::%:::::::::' ######º
 º########  ``::::::::::::::::::::::::::::::::::::''  #########º
  º##########   ```::::::::::::::::::::::::::'''   ###########º'
    `º#########-[---->+<]>++.[-->+++<]>..+++++++. ###########º'
      ` º#################################################º '
          ` º#######################################º '
             ` º#################################º '
                   ` º######################º '

Output:

happy birthday 007

Sangat nyaman bekerja untuk James Bond, tetapi tidak sampai 11 November.

James Webster
sumber
1
Woah ........... bagus!
mbomb007
Apakah bersih Brainfuck? Sepertinya itu tidak berhasil untuk saya ...
RedClover
16

Python 2, melayani 0

Pertama-tama, maaf, ini bukan kue dunia NYATA.

Namun, itu adalah salah satu game terbaik sepanjang masa, Portal.

Resep ini didasarkan pada apa yang dikatakan Intelijen Inti sebagai bahannya.

""" Happy Birthday, Chell!
* * * * * * * * * * * """
# Here are all the ingrediants for portal cake
candles = 1 # There is most certainly only one candle for her.
fish_shaped_dirt = 32 # There isn't an official amount of dirt to add, 32 seems like a nice number.

#Full of lies
lie = float('inf')

serves = None

# Show the tester the documentation on how to use this
print __doc__,

# Now, we are going to repeat these steps until chell stops lying.
while lie:
    # She did it again, so now we need to do the whole thing once more.
    print "\r",
    # Check how many candles her cake will have
    if candles:
        # We had better take them away from her. Maybe it will stop her lying so much
        candles = 0
    else:
        # Maybe if we give her a candle, she will listen
        candles = 1
    # See, her chances of lying go down when we give her candles!
    lie -= candles
    # Add the fish shaped dirt. But ONLY if we're giving her a candle.
    print chr(fish_shaped_dirt)*candles,
    # Add all the other rubbish
    print __doc__[25:],
    #Flush it into the relaxation vault
    import sys
    sys.stdout.flush()
    # Wait and ask her if she liked it.
    import time
    time.sleep(1)

Keluaran

 Happy Birthday, Chell!
 * * * * * * * * * * *

Diikuti oleh

 Happy Birthday, Chell!
  * * * * * * * * * * *

Kemudian berulang tanpa batas

Biru
sumber
8
Kue itu bohong.
orlp
1
Saya ingin memilih karena saya menyukai Portal, tetapi dengan kriteria saya sendiri saya tidak bisa! Bahkan jika saya bisa makan kue yang tidak bohong, itu akan terasa mengerikan. Kotoran tidak cocok untuk dimakan!
James Webster
6
Ini kemenangan.
James
1
Anda bahkan tidak menggunakan bahan-bahan terbaik. 1 rhuBARB terbakar, biskuit berbentuk ikan, sebuah buku tentang cara membunuh seseorang dengan tangan kosong, dll.
mbomb007
Itu melayani 0. Anda tidak pernah bisa mencukupi untuk membuat porsi. Oleh karena itu, Anda harus mendengarkan saya ketika saya mengatakan ini rasanya besar
Biru
16

Brengsek ***

Saya suka kue es krim, yang tidak perlu dipanggang. Juga, ini hari ulang tahunku, jadi jangan bilang kue macam apa yang bisa kumiliki.

Buy an ice cream cake:
    +   +   +    +   +   +
    |   |   |    |   |   |
[-]-[------->+<]>-.[--->++++<]
|><>+.-[++>-----<]>..+++++++++
|><.-[---->+<]>++.+[->++<]>.-[
|><--->+<]>--.+++++++++.++.---
|><---------.----.---.+[--->+<
|><]>+++.-[---->+<]>+++---+++|
then serve it.

Saya suka berpura-pura bahwa >+<]>itu adalah kerupuk berbentuk ikan.

mbomb007
sumber
1
Saya pikir ini layak diberi +1 untuk pencocokan 4/5 kriteria "kue terbaik". Saya akan memberikan Anda suara, tetapi pasti cut cornersdengan hanya membeli kue. 😞
James Webster
Saya juga bisa mempersonalisasikannya, tetapi itu akan membuat kue dua kali lebih besar. Itu juga tidak terlihat bagus.
mbomb007
Saya saat ini sedang berusaha membuat kue terlihat lebih mewah: P
James Webster
Aku membuatkanmu kue .
James Webster
@mikeTheLiar Saya kira Anda belum memainkan Portal atau membaca resep baru-baru ini? Membacanya lagi: theportalwiki.com/wiki/Core_voice_lines#Cake_core
mbomb007
8

Pip , melayani 2

Bagi kita yang selera ulang tahunnya sedikit lebih global ...

Our dessert tonight: " Birthday " Dosa!
(adapted from vegrecipesofindia.com/masala-dosa-recipe-how-to-make-masala-dosa-recipe)

1 cup rice: ("mmm, rice")
1 cup ukda chawal: [don't know what that is but it sounds good]
1/2 cup urad dal: ["dal" means lentils in Hindi]
1/4 cup poha: ["poha" is another kind of rice]
1/4 tsp methi seeds: ("!")
salt to taste: ["Happy" time]
water as needed: [you'll need some water]

Are you ready to cook? Yes? OK then:

1. rinse the rice and urad dal separately first.:
2. soak the ukda chawal, rice and poha.
3. in another bowl soak the urad dal-methi in enough water.
4. grind the urad dal with methi to a fine and fluffy batter.
5. grind the rice and poha to a smooth batter.
6. mix both the rice and urad dal batter with salt.
7. cover and let the batter ferment for 8-9 hours.

is it Ready? Y(es) or N(o)

Answer should be: y.
    take batter out and:

1. heat a flat cast-iron griddle and smear some oil on it.
3. spread the dosa batter in a circular way on the griddle; add some oil on top.
4. flip and cook the other side.
5. serve dosa hot with coconut chutney and sambar. (yum)

Recipe serves ___:
           `(?<=2) ?`
Actually, it serves exactly 2--half feR "ME" and half feR:_" YOU"!
Yeah! Happy birthday  !

Keluaran

Happy Birthday 2 YOU!

atau, jika Anda memasaknya:

Ulang Tahun Dosa

Sekarang aku lapar.

DLosc
sumber
1
Dosa dalam tantangan terkait memasak? Kedengarannya akrab ... ;-)
Tim Pederick
+1 untuk "Sekarang saya lapar." Terima kasih banyak, saya juga lapar sekarang.
bertepuk tangan
Sebagai catatan saya juga tidak tahu apa itu ukda chawal.
Alex A.
1

Koki, melayani 16.

Didasarkan dari ini . Saya tidak dapat menemukan penerjemah online, jadi saya mengikuti spesifikasi yang ditemukan di sini .

Versi "Golf"

"Happy" Birthday Cake.

This recipe was recovered from an *erm* ANCIENT cave, in which the culture consumed enormous amounts of eggs and water, and did so through their caves. Modern ingredients have been added in an endevour to make the cake better.

Ingredients.
48 teaspoons 2% milk
1 cup butter
1 l semisweet chocolate
73 eggs
2 teaspoons vanilla extract
1 cup sugar
1 teaspoon baking soda
5 teaspoons salt
24 g happiness
3 teaspoons water
8 ml corn starch
32 g space

Cooking time: 25 minutes.

Pre-heat oven to 162 degrees Celsius.

Method.
Put 2% milk into the mixing bowl. Add happiness to the mixing bowl. Put eggs into the mixing bowl. Add happiness to the mixing bowl. Put vanilla extract into the mixing bowl. Combine vanilla extract into the mixing bowl. Combine vanilla extract into the mixing bowl. Combine salt into mixing bowl. Add happiness to the mixing bowl. Add corn starch to the mixing bowl. Put vanilla extract into the mixing bowl. Combine vanilla extract into the mixing bowl. Combine vanilla extract into the mixing bowl. Combine salt into mixing bowl. Add happiness to the mixing bowl. Add corn starch to the mixing bowl. Put 2% milk into the mixing bowl. Add happiness to the mixing bowl. Add happiness to the mixing bowl. Add happiness to the mixing bowl. Add sugar to the mixing bowl. Put space into mixing bowl. Put happiness into the mixing bowl. Remove water from the mixing bowl. Combine vanilla extract into the mixing bowl. Add happiness to the mixing bowl. Put vanilla extract into the mixing bowl. Combine vanilla extract into the mixing bowl. Combine vanilla extract into the mixing bowl. Combine salt into mixing bowl. Add butter to the mixing bowl. Add happiness to the mixing bowl. Put space into the mixing bowl. Combine water into the mixing bowl. Remove water from mixing bowl. Remove water from mixing bowl. Add happiness to the bowl. Put space into the mixing bowl. Combine water into the mixing bowl. Remove water from mixing bowl. Remove semisweet chocolate from mixing bowl. Add happiness to the bowl. Put vanilla extract into the mixing bowl. Combine vanilla extract into the mixing bowl. Combine vanilla extract into the mixing bowl. Combine salt into mixing bowl. Add happiness to the bowl. Put 2% milk into the mixing bowl. Add happiness to the mixing bowl. Add happiness to the mixing bowl. Add sugar to the mixing bowl. Put eggs into the mixing bowl. Add happiness to the mixing bowl. Put eggs in mixing bowl. Add happiness to the mixing bowl. Add happiness to the mixing bowl. Put happiness into the mixing bowl. Put happiness into the mixing bowl. Remove sugar from the bowl. Remove baking soda from the bowl. Put space into mixing bowl. Put vanilla extract into the mixing bowl. Combine vanilla extract into the mixing bowl. Combine vanilla extract into the mixing bowl. Combine salt into mixing bowl. Add happiness to the mixing bowl. Add salt to the mixing bowl. Put eggs into the mixing bowl. Add happiness to the mixing bowl. Add butter to the mixing bowl. Add water to the mixing bowl. Put space into the mixing bowl. Add baking soda to the mixing bowl. Liquefy contents of the mixing bowl. Serves 16.

Output: Happy Birthday, me!.

Inilah penjelasan untuk setiap langkah:

"Happy" Birthday Cake.

This recipe was recovered from an *erm* ANCIENT cave, in which the culture consumed enormous amounts of eggs and water, and did so through their caves. Modern ingredients have been added in an endevour to make the cake better.

Ingredients.
48 teaspoons 2% milk
1 cup butter
1 l semisweet chocolate
73 eggs
2 teaspoons vanilla extract
1 cup sugar
1 teaspoon baking soda
5 teaspoons salt
24 g happiness
3 teaspoons water
8 ml corn starch
32 g space

Cooking time: 25 minutes.

Pre-heat oven to 162 degrees Celsius.

Method.

Put 2% milk into the mixing bowl.               48
Add happiness to the mixing bowl.                +24= 72 (H)

Put eggs into the mixing bowl.                  73
Add happiness to the mixing bowl.                +24= 97 (a)

Put vanilla extract into the mixing bowl.       2
Combine vanilla extract into the mixing bowl.   *2 = 4
Combine vanilla extract into the mixing bowl.   *2 = 16
Combine salt into mixing bowl.                  *5 = 80
Add happiness to the mixing bowl.                +24=104
Add corn starch to the mixing bowl.             +8 =112 (p)

Put vanilla extract into the mixing bowl.       2
Combine vanilla extract into the mixing bowl.   *2 = 4
Combine vanilla extract into the mixing bowl.   *2 = 16
Combine salt into mixing bowl.                  *5 = 80
Add happiness to the mixing bowl.                +24=104
Add corn starch to the mixing bowl.             +8 =112 (p)

Put 2% milk into the mixing bowl.               48
Add happiness to the mixing bowl.                +24= 72
Add happiness to the mixing bowl.                +24= 96
Add happiness to the mixing bowl.                +24=120
Add sugar to the mixing bowl.                   +1 =121 (y)

Put space into mixing bowl.                     32      ( )

Put happiness into the mixing bowl.              24
Remove water from the mixing bowl.              -3 = 21
Combine vanilla extract into the mixing bowl.   *2 = 42
Add happiness to the mixing bowl.                +24= 66 (B)
Put vanilla extract into the mixing bowl.       2
Combine vanilla extract into the mixing bowl.   *2 = 4
Combine vanilla extract into the mixing bowl.   *2 = 16
Combine salt into mixing bowl.                  *5 = 80
Add butter to the mixing bowl.                  +1 = 81
Add happiness to the mixing bowl.                +24= 95 (i)

Put space into the mixing bowl.                 32
Combine water into the mixing bowl.             *3 = 96
Remove water from mixing bowl.                  -3 = 93
Remove water from mixing bowl.                  -3 = 90
Add happiness to the bowl.                      +24=114 (r)

Put space into the mixing bowl.                 32
Combine water into the mixing bowl.             *3 = 96
Remove water from mixing bowl.                  -3 = 93
Remove semisweet chocolate from mixing bowl.    -1 = 92
Add happiness to the bowl.                      +24=116 (t)

Put vanilla extract into the mixing bowl.       2
Combine vanilla extract into the mixing bowl.   *2 = 4
Combine vanilla extract into the mixing bowl.   *2 = 16
Combine salt into mixing bowl.                  *5 = 80
Add happiness to the bowl.                       +24=104 (h)

Put 2% milk into the mixing bowl.               48
Add happiness to the mixing bowl.                +24= 72
Add happiness to the mixing bowl.                +24= 96
Add sugar to the mixing bowl.                   +1 = 97 (d)

Put eggs into the mixing bowl.                  73
Add happiness to the mixing bowl.                +24= 97 (a)

Put eggs in mixing bowl.                        73
Add happiness to the mixing bowl.                +24 = 97
Add happiness to the mixing bowl.                +24 =121(y)

Put happiness into the mixing bowl.              24
Put happiness into the mixing bowl.              +24= 48
Remove sugar from the bowl.                     -3 = 45
Remove baking soda from the bowl.               -1 = 44 (,)

Put space into mixing bowl.                     32      ( )

Put vanilla extract into the mixing bowl.       2
Combine vanilla extract into the mixing bowl.   *2 = 4
Combine vanilla extract into the mixing bowl.   *2 = 16
Combine salt into mixing bowl.                  *5 = 80
Add happiness to the mixing bowl.                +24=104
Add salt to the mixing bowl.                    +5 =109 (m)

Put eggs into the mixing bowl.                  73
Add happiness to the mixing bowl.                +24=97
Add butter to the mixing bowl.                  +1 =98
Add water to the mixing bowl.                   +3 =101 (e)

Put space into the mixing bowl.                 32
Add baking soda to the mixing bowl.             +1 = 33 (!)

Liquefy contents of the mixing bowl.            Converts the mixing bowl to characters

Serves 16.                                      Outputs the contents of the first
                                                16 bowls.
Conor O'Brien
sumber
Bukankah itu dieja "kebahagiaan," atau apakah nama harus dengan cara tertentu?
cole
Maaf, tulis di blok kode saya. Saya lupa saya telah mematikan koreksi-otomatis.
Conor O'Brien
Saya juga belum menjalankan ini, tapi saya pikir Anda sudah mendapatkan semuanya dalam 1 mangkuk pencampuran, kemudian mencoba untuk menghasilkan 16.
James Webster
@ JamesWebster Spesifikasi mengatakan bahwa Serves Npernyataan ini mengeluarkan semua bahan dalam setiap mangkuk dari 1 hingga N.
Conor O'Brien
Ya, tetapi Anda hanya menggunakan satu mangkuk. Mangkuk 2-15 kosong / tidak ada.
James Webster