I am doing an assignment for school and using putty to complete the assignment. The format of the assignment does not allow for much variation and thus only one answer is sufficient enough to allow me to move on to the next question. They also want the shortest possible pathnames and commands used to get to the answer.
Your current directory is sample_dir. Find the records in cars2 that contain the string "ford" and display the number of characters in the result. sample_dir2
-- sample_dir |-- admin |-- cambridge | `-- security | |-- annex | `-- parking |-- history.exe |-- markham | |-- annex | |-- building1 | `-- parking `-- stenton |-- f1 |-- f12 |-- f2 |-- gen_ed | |-- Holidays | `-- cars2 |-- lib_arts | `-- english.txt `-- phone_directory | |-- Holidays | `-- cars2 |-- lib_arts | `-- english.txt `-- phone_directory
grep -c ford stenton/gen_ed/cars2 and different options using
grep. Is this along the right path or am I way off?