cs190/labs/lab2/answers.txt

48 lines
1.1 KiB
Plaintext
Raw Permalink Normal View History

2018-10-15 17:08:50 -04:00
# CS190 Lab2 Answer Sheet
# ==========================
# Directions
# ==========================
# Follow the format below to answer each numbered task.
#
# -----------------
# Task 0 Answer
# -----------------
cat file.txt | wc -l
# ==========================
# Beginning of answer sheet.
# ==========================
# -----------------
# Task 1 Answer
# -----------------
wget https://github.com/Purdue-CSUSB/CS-190-F2016/raw/master/labs/lab2/answers.txt
# -----------------
# Task 2b Answer
# -----------------
bash madlib < input.xt > poem.txt
# -----------------
# Task 3 Answer
# -----------------
grep -wn "horseman" The\ Young\ Engineers.txt
# 3369:later Harry, though not a crack horseman, left camp at a gallop.
# 4044:before. Then a horseman drew up before their tent.
# 4053:"Yes, sir," replied the young horseman.
# 4656:"No, son; I want your father," explained the horseman.
# 4666:the horseman.
# 4809:a clear bit of trail, a horseman riding in at a furious gallop.
# -----------------
# Task 4 Answer
# -----------------
grep -nr "Are you sure you want to quit DrJava?" ./*
# FILENAME: ./src/edu/rice/cs/drjava/ui/MainFrame.java
# LINE NO.: 5331