Skip to main content

Quiz Generator

Project description

Mostx : Quiz Generator

import mostx

print(sorted(mostx.get_available_langs()))
# => ['chinese', 'english', 'japanese', 'korean', ]

qgen = mostx.QuizGenerator(lang='english')
q = qgen.generate(choices='ABC', n_adjectives=1)

for s in q.statements:
    print(s)
# B is quieter than A
# C is quieter than A
# B is quieter than C
print(q.question)  # => Which is the noisiest?
print(tuple(q.choices))  # => ('A', 'B', 'C')
print(q.answer)  # => A

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mostx-0.1.0.tar.gz (3.9 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page