CSE15LFall13MidtermExamPracticeQuestions

Java rw rw r 1 u1 lec 168 may 7 1300 makefile now

Info icon This preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: ’ in the manual page for Unix command called “time”. 10. What is the function of the Unix environment variable “PATH”. 11. Which of the following will send standard error from prog to file, and discard standard output? a. prog > file < /dev/null b. prog > /dev/null 2> file c. prog < file > /dev/null d. prog 1> file 2> /dev/null 12. List two cons and two pros of unit testing. 13. Which file does make look for in the current working directory? 14. For this problem, consider this Makefile: A.class: A.java javac A.java B.class: A.class B.java javac B.java C.class: B.class A.class C.java javac C.java all: C.class B.class A.class a. Suppose ls - l produces this output: -rw-rw-r-- 1 u1 lec 150 May 7 13:16 A.java -rw-rw-r-- 1 u1 lec 81 May 7 13:25 B.java -rw-rw-r-- 1 u1 lec 189 May 7 13:20 C.java -rw-rw-r-- 1 u1 lec 168 May 7 13:00 Makefile Now running make all will cause what command(s) to be executed? List them. b. Suppose ls - l produces this output: -rw-rw-r-- 1 u1 lec 356 May 7 13:50 A.class -rw-rw-r-- 1 u1 lec 150 May 7 13:16 A.java -rw-rw-r-- 1 u1 lec 251 May 7 13:50 B.class -rw-rw-r-- 1 u1 lec 69 May 7 13:25 B.java -rw-rw-r-- 1 u1 lec 532 May 7 13:50 C.class -rw-rw-r-- 1 u1 lec 189 May 7 13:...
View Full Document

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern