The University of Western Australia
Computer Science and Software Engineering

Department of Computer Science and Software Engineering

CITS4407 Open Source Tools and Scripting

Assignment 1 Clarifications

Back to Assignment 1.

This page provides any clarifications, more detailed explanations, or corrects any errors identified after the project description was released. This page will be updated with responses to any common problems or misunderstandings posted on help4407 or asked via email.

For all tasks you may assume that the correct number of command-line arguments are provided, that all inputs are in the correct format, and that any input files exist and are readable.

Task 1 - days between dates
  • 4th April - the two dates will both be valid (formats), and may be in different years.

Task 2 - Lotto ticket
  • 3rd April - the 6 numbers on a Lotto ticket must be distinct, no repeats.

  • 7th April - do not use the shuf command.
    Else it's a bit easy with shuf -i 1-45 -n 6
    In practice, there won't be such esoteric commands available to solve your general problems!

Task 3 - bookindex
  • 3rd April - only bracketed words and phrases are to appear in the index. A textfile with both <Linux> and Linux will only have one index entry for 'linux'. The alphabetic case of index entries should be ignored, and all index entries will appear in lowercase. A textfile with both <Linux> and <linux> will have one index entry for 'linux' with two line numbers.

Task 4 - Titanic families
  • 7th April - your shellscript may have any name you choose.

  • 9th April - your shellscript may assume that the file named titanicdata.csv is in your working directory.


Chris McDonald
April 2020.

This Page

Written by: [email protected]