change FLUSH_MIN to 5; add docs to card; prevent duplicates in random and stdin