================================================================= Assignment #13 (REVIEW ONLY) - HTML and CSS (NOT FOR HAND IN) ================================================================= - Ian! D. Allen - idallen@idallen.ca - www.idallen.com This is a set of review questions only. It is not for hand in. Do not submit this assignment. It is only for review. 0. What is the date and room location of your CST8281 Final Exam? 1. Write the simplest IF statement (simplify the Boolean logic) for the following programming problem specification: A widjet is "stale" if TIME is more than 60 AND ACCESS is more than 100. A widjet is "risky" if it is NOT stale, AND TIME is more than 60. Call the notify() routine if the widjet is NOT risky. - Write down what the specifications say: stale = TIME > 60 && ACCESS > 100 risky = NOT stale && TIME > 60 NOT risky = NOT ( NOT stale && TIME > 60 ) - apply deMorgan: NOT risky = stale || TIME <= 60 - substitute for "stale": NOT risky = ( TIME > 60 && ACCESS > 100 ) || TIME <= 60 - Since NOT(TIME > 60) == (TIME <= 60) we can simplify: - The above is in Boolean form: a' = (bc) + b' - Distribute and rewrite as: a' = (b + b')(c + b') - Identity: a' = (1)(c + b') - Identity: a' = c + b' - Simplified result: NOT risky = ACCESS > 100 || TIME <= 60 ANSWER: CLS = "Course Linux Server" 2. What is the absolute Linux pathname of the CLS home directory for user abcd0001? ANS: 3. What is the absolute Linux pathname of the CLS public web directory for user abcd0001? ANS: 4. You are using FTP or SFTP on a Windows computer. Your current Windows directory is C:\Windows and you connect using userid abcd0001 to the CLS. Give the "put" command that will copy a local file "foo.txt" from the "Temp" directory on your Windows "E:" drive to the CLS so that the following URL will display the contents of that file. Note the new file name: http://cst8281.idallen.ca:8080/~abcd0001/a10/bar.txt ANS: (I assume the FTP connection connects to the abcd0001 home directory) 5. What is the absolute Linux pathname of the file accessed by this URL: http://cst8281.idallen.ca:8080/~abcd0001/a10/bar.txt ANS: 6. Complete this URL to access the Linux file ~abcd0001/public_html/foo.txt http://cst8281.idallen.ca:8080/_______________________________ ANS: 7. Generate the HTML for this table with a border: +-----------+ | one | two | |-----------| | me | you | |-----------| | chocolate | +-----------+ ANS: ----------------------------------------------------------------------- CSS attributes to be tested are listed in Class Notes file: 300_css.txt Cascading Style Sheets - Basic 8. What are the CSS attribute names for modifying these style properties: (Reference: http://www.w3schools.com/css/css_boxmodel.asp ) * colour of text * colour of the background * font name * positioning the element on the page absolutely * setting the distance to the top of the page * setting the distance to the left side of the page * setting the width of the element * setting the border * setting the spacing outside the border * setting the spacing between the border and the element content 9. What are the only children of in the Document Tree? True/False: every

has as an ancestor. True/False: every

has as an ancestor. True/False: every

has as an ancestor. True/False: every has as an ancestor. True/False: every has as an ancestor. True/False: every tag is a descendant of . True/False: every tag is a descendant of . True/False: every tag is a descendant of . What is the difference between a block element and an inline element? Which type of element (block/inline) is

? Which type of element (block/inline) is ? Which type of element (block/inline) is

? Which type of element (block/inline) is ? Which type of element (block/inline) is ? Which type of element (block/inline) is

? Which type of element (block/inline) is ? Which type of element (block/inline) is