generate random text based on an input file.
can save the text to a file or simply print it to stdout.
nothing smart nor sophisticated, you wont find any A.I.,bots,nor sophisticated algorithms here.(who do you think we are, some city slicker with a fancy german built car and gucci loafers?)
- run main.lua with these three arguments:
- input file
- the file containing the input text. should be a simple text file.
- length
- how many words to generate based on input. should be a positive integer value.
- finish sentence
- boolean to decide whether to keep generating random text after limit is hit until a complete sentence is formed. default is false.
- output file
- the file to write text to. if none is included then default to using stdout.
- input file
- here is an example of 100 random words generated by using 'Moby Dick' as the input text:
between a young sucking whale and a full-grown Platonian Leviathan; yet, even in the limitless, uncharted seas, he revealed his identity, at a long distance, to those who like them. For my part, I abominate all honorable respectable toils, trials, and tribulations of every kind whatsoever. It is quite as much as comported with his humor, the Lakeman paused on the hatches there where you sit, and listen as you listen, while some one of you reads _me_ that other and more vital practical influences at work. Not even at the present day, we occasionally hear of English and American vessels, which, in