Practice Evaluation (Medium)

You have 20 minutes to complete this evaluation.

Use the regexquiz tool to write a regular expression that recognises numbers between 0 and 255.

The expression should recognise numbers that have leading 0’s.

For example 010 is a valid number between 0 and 255.

Instructions for trying the easy problem

1. Open a command window and start the regexquiz. You can use either of the following commands to start the quiz:

$ regexquiz medi

RegExQuiz! ICS 215 RegEx quizzer.
Type #question to see the quiz question. Then type in the regular
expression that solves the question. When you hit return the quizzer
will show you lines that match that regex, or nothing if nothing matches.
Type #quit to quit.

Loaded Quiz medi

Write a regular expression that recognises numbers between 0 and 255. The expression should recognise numbers that
have leading 0's. For example 010 is a valid number between 0 and 255.

quiz >

2. Start entering your regular expression to match numbers between 0 and 255.

3. When you have your solution, quit regexquiz by typing “#quit” at the command prompt.

4. Find the text file with the name <username>medi.txt

This file is automatically created by regexquiz. It includes the commands that you typed in the quizzer. On my laptop the filename is carletonmooremedi.txt.

5. Email the file to Cam and Jan

Send an email with the file attached to cmoore@hawaii.edu and dufek@hawaii.edu. The timestamp on the email will indicate when you completed the quiz. For an easy quiz you have 20 minutes to complete the problem.

Watch me solving the problem

After trying out the problem you can watch me solve the problem.