The tag has no usage guidance.

learn more… | top users | synonyms

6
votes
0answers
160 views

Please parse this aLL1en language

Due to some unfortunate accident during coding you are now teleported and stranded on an alien planet. You really hope that the locals will be helpful and point to the general direction of how to get ...
8
votes
0answers
188 views

Find the follow sets

The challenge below requires you to be familiar with formal parser theory. If you don't know what the question is asking because you don't know what the terms mean, context-free grammars and ...
0
votes
3answers
212 views

Create a Question Asker! [closed]

Writing questions for programming puzzles is tiring and takes many minutes to do. This is where you come in. Your job is to write a program that randomly generates plausible-sounding (but not ...
7
votes
2answers
603 views

Compress data with context free grammars

It is possible to compress some kinds of data, such as human text or source code, with straight-line grammars. You basically create a grammar whose language has exactly one word – the uncompressed ...
7
votes
1answer
290 views

Write a CFG acceptor

Write a program that, given a context free grammar and a string, returns whether the string is a word of the language defined by the grammar. Input Your program should read a context free grammar ...
6
votes
1answer
830 views

Random Sentence Generator

Write the shortest program you can in any language that reads a context-free grammar from and the number of sentences to produce from stdin, and generates that many random sentences from the grammar. ...