Assignment 2 Instructions for preparing the assignment submission 1. It is compulsory to use either text editor vim or emacs while editing the Latex source file. 2. The Latex source file should have...

1 answer below »
plz find the attachment


Assignment 2 Instructions for preparing the assignment submission 1. It is compulsory to use either text editor vim or emacs while editing the Latex source file. 2. The Latex source file should have three sections; The answer to each question should be edited within one section. The BASH script for Q2 and Q3 should be included in the Latex document with the verbatim environment. 3. The Latex source file should be in 11pt font and in the article class. The document has a title, your name (or student ID), and a table of contents, plus a number of sections. 4. Linux utility (either pdflatex or latex) must be used to generate the output PDF file from the Latex source file. 5. Submit both Latex source document and the generated PDF file. Question 1. (20 marks) Create a short resume of yours in Section 1. Section 1 includes · at least one subsection introducing yourself and all the courses you enrolled in this semester. · one subsection that typeset an unnumbered formulae · one subsection has the following numbered mathematical formula (1). · one subsection has a floating table with caption. It should look like the one shwon in Table 1, except that the table number could be different. · one subsection has a short biography of yourself, alongside with your recent photo. Note: 1. You don't have to use the multirow package to create the table as given. 2. The figure number or table number could be different than the number shown as given. Question 2. (20 marks) Write a well structured Bash script which deletes all the standard comments/remarks from a C program. A standard comment line in C programs starts with the two-characters token (/*) and ends with the two-characters token (*/). You may assume that each standard comment line contains the start and end tokens without any other statements before and after. Below is a snippet of C program: /* a comment line in a C program */ printf("It is /* NOT a comment line */\n"); x = 5; /* This is an assignment, not a comment line */ [TAB][SPACE] /* another empty comment line here */ /* another weird line, but not a comment line */ y = 0; You can test your Bash script on the snippet of C program which contain all above four lines. The expected out from your script should look like: printf("It is /* NOT a comment line */\n"); x = 5; /* This is an assignment, not a comment line */ /* another weird line, but not a comment line */ y = 0; Note: 1. If the script is executed without argument, it should print out a message as shown below, $ myscript Usage: myscript inputfile-name outputfile-name This script will remove all the standard comment lines from C program file. 2. where [TAB][SPACES] denote there could be some TAB key or white spaces in front of the line. 3. Your script should read inputs from a text file, and write outputs into another file, and all the I/O file names must be given in the command-line. 4. Linux utility sed is recommended to use in your script. Question 3. (20 marks) Write a short but well structured Bash script that takes the input filename and the output filename as arguments from the command line. The script should read all lines from the input file, and delete all the lines that contain more than one word. Then write all those lines in which there is a single English word (could be a number or punctuation mark) into the output file. Here is an example of the input file. This is a special text file There[SPACE][SPACE] are 60 students enrolled in this course. [TAB][SPACE] Nearly half of that number of students are in the Faculty of HES. The rest of them are from the Faculty-of-BLA.[TAB] The output file should contain the following lines only. There[SPACE][SPACE] [TAB][SPACE] Nearly Faculty-of-BLA.[TAB] Note: 1.'Well structured' means the script must have the error checking and robustness checking. 2. The syntax of the script should be 'myscriptname -i inputfile -o outputfile'. 3. The composite word can be any English letters linked by dash. For instance, Faculty-of-HES is regarded as one word. 4. Where [TAB] and/or [SPACE] are the whitespace and/or TAB keys.(They are unnoticeable by eyes)
Answered Same DaySep 29, 2021

Answer To: Assignment 2 Instructions for preparing the assignment submission 1. It is compulsory to use either...

Sudipta answered on Oct 03 2021
156 Votes
\documentclass[11pt]{article}
\usepackage[utf8]{inputenc}
\usepackage{makecell}
\usepackage{amsma
th}
\usepackage{multicol}
\usepackage{float}
\usepackage{graphicx}
\usepackage{wrapfig}
\begin{document}
\title{CSC2408 Software Development Tools}
\author{Harsimranjeet Kaur}
\date{}
\maketitle
\tableofcontents
\section{Section 1}
\subsection{Introduction}
\begin{flushleft}
Hi! This is Harsimranjeet Kaur with nationality of Indian and studying in University of Southern Queensland. The course in which I am enrolled are Communication and Scholarship (CMS1000), Foundation Programming (CSC1401), Software Development Tools(CSCS2408)and Data Analysis (STA2300).
\end{flushleft}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Unnumbered equation}
$\begin{array}{*{20}c}
{x =\frac{{ - b \pm \sqrt {b^2 - 4ac} }}{{2a}}}
\end{array}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%
$
%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\subsection{Number...
SOLUTION.PDF

Answer To This Question Is Available To Download

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here