MATH 241 Midterm: MATH 241 UPenn 241Fall 04Makeup Exam

19 views14 pages
31 Jan 2019
School
Department
Course
Professor

Document Summary

My signature below certi es that i have complied with the university of pennsylvania"s code of. All of the following questions refer to java programming. a. Whenever you override the equals method of a class, you should be sure to override the hashcode method compatibly. b. If a is a subtype of b, then set is a subtype of set. c. When using the java io libraries, one should generally wrap a filereader object inside a bufferedreader to prevent signi cant performance problems. d. e. f. g. h. i. It is possible to create an object of type set. An object"s static type is always a subtype of its dynamic type. The value null can be assigned to a variable of any type. A method with the following declaration de nitely will not throw an ioexception to a calling context. public void m() {} The @override annotation prevents accidental overloading of a method.