QUIZ(6)

πŸ’… QUIZ(6) β€” the games manual page, bestie edition ✨

okay so real talk: this is quiz from the Games Manual section 6, and it's literally the most fun you can have in a terminal, no cap πŸŽ€


✨ NAME ✨

quiz β€” random knowledge tests πŸ§ πŸ’–


🌸 SYNOPSIS 🌸

quiz [-t] [-i file] [question answer]

πŸ¦‹ DESCRIPTION πŸ¦‹

The quiz utility tests your knowledge of random facts. It has a database of subjects from which you can choose. With no arguments, quiz displays the list of available subjects. like, it just shows you the menu, very demure 🫢

The options are as follows:

  • -t β€” Use tutorial mode, in which questions are repeated later if you didn't get them right the first time, and new questions are presented less frequently to help you learn the older ones. it's giving study buddy energy fr πŸ“šβœ¨
  • -i β€” Specify an alternative index file. yes bestie, you can bring your own index πŸ’…

Subjects are divided into categories. You can pick any two categories from the same subject. quiz will ask questions from the first category and it expects answers from the second category. For example, the command quiz victim killer asks questions which are the names of victims, and expects you to answer with the cause of their untimely demise, whereas the command quiz killer victim works the other way around. πŸ”₯ wild, iconic, slightly concerning, we love it

If you get the answer wrong, quiz lets you try again. To see the right answer, enter a blank line. no pressure tho 😭 just hit enter on an empty line and it'll spill the tea β˜•


🧚 Index and Data File Syntax 🧚

The index and data files have a similar syntax. Lines in them consist of several categories separated by colons. The categories are regular expressions formed using the following meta-characters:

pat|pat  alternative patterns
{pat}    optional pattern
[pat]    delimiters, as in pat[pat|pat]pat

so like, pat|pat = this or that, {pat} = maybe this maybe nothing, and [pat] = delimiters, as in pat[pat|pat]pat. the brackets are literally just the frame, iykyk πŸ–ΌοΈ

In an index file, each line represents a subject. The first category in each subject is the pathname of the data file for the subject. The remaining categories are regular expressions for the titles of each category in the subject. πŸ“‚βœ¨

In data files, each line represents a question/answer set. Each category is the information for the question/answer for that category. πŸŽ€

The backslash character (`\') is used to quote syntactically significant characters, or at the end of a line to signify that a continuation line follows. yes the backslash is that girl β€” she escapes stuff AND she says "to be continued" πŸ’…βž‘οΈ

If either a question or its answer is empty, quiz will refrain from asking it. considerate king behaviour honestly πŸ‘‘


⭐ FILES ⭐

  • /usr/share/games/quiz β€” The default index and data files. the mothership πŸ›ΈπŸ’–

πŸ’€ BUGS πŸ’€

quiz is pretty cynical about certain subjects. not me getting roasted by a manpage 😭🫢


lowkey the vibe check here: every option, every file path, every meta-character is exactly where it should be. go forth and get your trivia on, bestie πŸ¦‹πŸŒˆ

🌸 signing off, xoxo β€” this page comes from Debian, dated May 31, 1993 πŸ’œ (yes she's an elder icon and she's still slaying)

πŸ“¦ where this page comes from