flat assembler
Message board for the users of flat assembler.

Index > Heap > Poetry generator in BASIC.

Author
Thread Post new topic Reply to topic
mbr_tsr



Joined: 03 Apr 2011
Posts: 4903
mbr_tsr
dim Word1$(30)
dim Word2$(30)

Word1$(1) = "Song gone really wrong"
Word1$(2) = "Night fear too far near"
Word1$(3) = "Holy good without should"
Word1$(4) = "Dark wish rest fish"
Word1$(5) = "Asking more final score"
Word1$(6) = "Deal without heal"
Word1$(7) = "Years sorry tears"
Word1$(8) = "Kings scary rings"
Word1$(9) = "Start without a part"
Word1$(10) = "Never risk the disk"
Word1$(11) = "Fight long while strong"
Word1$(12) = "Symbols clear are here"
Word1$(13) = "Dreams black attack"
Word1$(14) = "Fantasy one not done"
Word1$(15) = "Not fair in my share"
Word1$(16) = "King wish silver dish"
Word1$(17) = "Holy good only should"
Word1$(18) = "Wounded man now I can"
Word1$(19) = "Evil sin poison win"
Word1$(20) = "Dark error wicked terror"
Word1$(21) = "Forever time chime"
Word1$(22) = "Worry event penny spent"
Word1$(23) = "Invest in only one test"
Word1$(24) = "Boy found great joy"
Word1$(25) = "Ages bring new stages"
Word1$(26) = "Boil rock cook book"
Word1$(27) = "Free for all wild call"
Word1$(28) = "Monsters strive to be alive"
Word1$(29) = "Sail ships rack tips"
Word1$(30) = "Hero star takes us far"

Word2$(1) = "price of mine nice"
Word2$(2) = "only do right for delight"
Word2$(3) = "logic zaps taking naps"
Word2$(4) = "over seas land on trees"
Word2$(5) = "I put my best on the test"
Word2$(6) = "peace not fail north sail"
Word2$(7) = "no laws in the claws"
Word2$(8) = "taste a drop never stop"
Word2$(9) = "my crew also needs you"
Word2$(10) = "device will suffice"
Word2$(11) = "lock down my town"
Word2$(12) = "duck avoids the truck"
Word2$(13) = "poison date unlock gate"
Word2$(14) = "only truth is youth"
Word2$(15) = "beer and ice packed nice"
Word2$(16) = "tingle brain in rain"
Word2$(17) = "one glitch forever witch"
Word2$(18) = "celebrate ago work we know"
Word2$(19) = "forgotten stages lost ages"
Word2$(20) = "I never got my full lot"
Word2$(21) = "from 1 to 10 has not been"
Word2$(22) = "stare into my priceless share"
Word2$(23) = "gaze into a special maze"
Word2$(24) = "life is bad without dad"
Word2$(25) = "broken sail wind wail"
Word2$(26) = "evil greed fills my need"
Word2$(27) = "good troop lost at full cost"
Word2$(28) = "win at last story stash"
Word2$(29) = "ship sails tonight delight"
Word2$(30) = "orbit power wings tower"

screen 0

randomize
Main:
cls
color 15,0
print "DARK FEARS AND FORBIDDEN HOPES POETRY"

for J = 1 to 20
Redo1:
k1 = rnd(0)
k1 = k1 mod 30
k1 = k1 + 1
if old1 = k1 then Redo1:
old1 = k1

Redo2:
k2 = rnd(0)
k2 = k2 mod 30
k2 = k2 + 1
if old2 = k2 then Redo2:
old2 = k2

color 13,0
print j;
color 14,0
print Word1$(k1);
print " ";
print Word2$(k2);
print ","

next j

color 11,0
print "Press any key to restart or q to exit..."
k$ = ""
while k$ = ""
k$ = inkey$
wend
k$ = lcase$(k$)
if k$ = "q" then
END
endif
goto Main:
Post 26 Jun 2014, 11:16
View user's profile Send private message Reply with quote
DOS386



Joined: 08 Dec 2006
Posts: 1901
DOS386
Code:
if k$ = "q" then
END
endif
goto Main:
    


NOT only desperately inefficient, but it even has a BUG !!! Should be:

Code:
if k$ = "q" then
PEND
endif
goto Hell!
    
Post 26 Jun 2014, 11:52
View user's profile Send private message Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Copyright © 1999-2020, Tomasz Grysztar.

Powered by rwasa.