Faculty of Engineering and Mathematical Sciences 
Not logged in (login)

help4407


This forum is provided to promote discussion amongst students enrolled in Open Source Tools and Scripting (CITS4407).
 
Options:
RSS cloud
Jump to:

Task 3 - Assignment 1

5 of 390 articles shown, currently no other people reading this forum.
photo
From: Rohit A.
Date: Mon 13th Apr 2020, 4:19pm
Actions: 
        Login-to-reply

 

Hi, 

For task 3 of assignment 1, need clarifications on the following doubts: 

a.) Will words within angled brackets contain special characters and numbers as well? 
If yes, then are we suppose to consider them as part of the word or extract just the 
alphabets within them and add entries to the index accordingly. For e.g will the 
words <@l*n*x> and <linux2> be two separate words or they should be added to the 
index of common word 'linux' ?

b.) About words with spaces in them: if we've two words like < linux > and <linux > 
i.e words which have same alphabets but different space position within the angled 
brackets, then are we supposed to consider these kinds of words as just one word 
"linux" or two different words " linux " and "linux " ?

Thank you. 

Task 3 - Assignment 1

photo
From: Christopher M.
Date: Mon 13th Apr 2020, 4:33pm
Actions: 
        Login-to-reply

 

"Rohit Atri" <22*1*1*[email protected]*u*e*t*u*a*e*u*a*> wrote:

> a.) Will words within angled brackets contain special characters and numbers as well? 
> If yes, then are we suppose to consider them as part of the word or extract just the 
> alphabets within them and add entries to the index accordingly. For e.g will the 
> words <@l*n*x> and <linux2> be two separate words or they should be added to the 
> index of common word 'linux' ?

I appreciate your concern and desire to get this correct, but you're "overthinking it".

Yes, ANY characters may appear within the angle brackets.
If the character sequences between two sets of angle brackets are different,
then they result in different index terms  (other than alphabetic case being mapped to 
lowercase).

If the book author makes a mistake in how they mark the desired index entries, than that's their 
task to fix the entries,  not for the shellscript writer to guess what the author may have meant.

 
> b.) About words with spaces in them: if we've two words like < linux > and <linux > 
> i.e words which have same alphabets but different space position within the angled 
> brackets, then are we supposed to consider these kinds of words as just one word 
> "linux" or two different words " linux " and "linux " ?

As for your first question.

Task 3 - Assignment 1

photo
From: Rohit A.  O.P.
Date: Mon 13th Apr 2020, 7:41pm
Actions: 
        Login-to-reply

 

Thank you for the clarification.

Task 3 - Assignment 1

photo
From: Rohit A.  O.P.
Date: Wed 15th Apr 2020, 8:20pm
Actions: 
        Login-to-reply

 

Hi Chris, 

As per your reply and my further feeble understanding on how/what the input might be, I am considering 
the white spaces before and after main text/characters within the braces. 

i.e I am considering < linux> , < linux > and <linux> as three separate words. 

I hope its fine and is the way you want us to define words and print index accordingly. 

Task 3 - Assignment 1

photo
From: Christopher M.
Date: Thu 16th Apr 2020, 4:27am
Actions: 
        Login-to-reply

 

"Rohit Atri" <22*1*1*[email protected]*u*e*t*u*a*e*u*a*> wrote:

> i.e I am considering < linux> , < linux > and <linux> as three separate words. 

Hi Rohit,

Yes, that is the correct interpretation.
(For this assignment) it is not the role of the script writer to correct possible mistakes of the book author.
This Page


Program written by: [email protected]
Feedback welcome
Last modified: 11:27am Sep 21 2020