Skip to content

Add long vocals #4

Merged
merged 1 commit into from
Nov 25, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion chicken.pl
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
) or die USAGE;

my @WORDS
= ( "puk", "pukaaak", "cluck", "cluckity", "bwak", "waaak", "bok", "bwok", "cluck-a-buh-gawk", "cock-a-doodle-doo", "bwwwaaaaaaaaaak", "gobble", "honk", );
= ( "puk", "pukaak", "cluck", "cluckity", "bwak", "waak", "bok", "bwok", "cluck-a-buh-gawk", "cock-a-doodle-doo", "bwwwaak", "gobble", "honk");

my @PUNCTUATIONS = ( ".", "...", "!", "?" );

Expand Down Expand Up @@ -48,6 +48,9 @@
# magic multiplier
$word = join( "-", ($word) x ( 4 - int( ( log( rand(7) + 1 ) / log(2) ) + 1 ) ) );

# even more magical multiplier
$word =~ s/([aou]){2,}?/$1 x (rand(7)+1)/ge;

# optionally add punctuation
# note: always add punctuation if it's the last word.

Expand Down