100% satisfaction guarantee Immediately available after payment Both online and in PDF No strings attached
logo-home
CSE 2221 Midterm 2 Exam/42 Accurate Questions with Answers $8.49   Add to cart

Exam (elaborations)

CSE 2221 Midterm 2 Exam/42 Accurate Questions with Answers

 7 views  0 purchase
  • Course
  • CSE 2221
  • Institution
  • CSE 2221

CSE 2221 Midterm 2 Exam/42 Accurate Questions with Answers

Preview 2 out of 5  pages

  • September 26, 2024
  • 5
  • 2024/2025
  • Exam (elaborations)
  • Questions & answers
  • CSE 2221
  • CSE 2221
avatar-seller
Nursephil2023
CSE 2221 Midterm 2 Exam/42 Accurate
Questions with Answers
Precondition - - characterizes the responsibility of the program
that calls the method (the client)

- Post-condition - - characterizes the responsibility of the program that
implements the method (the implementer)

- Parameter Mode - - Part of the contract that specifies the way a method
might change the value of the corresponding argument.

- Clears - - A parameter mode. Upon returning from a method call, a clears-
mode parameter has the initial value for its type.

- Restores - - The default parameter mode. Upon returning from a method
call, a restores-mode parameter has the value it had when it was passed into
the method.

- Replaces - - A parameter mode. Upon returning from a method call, a
replaces-mode parameter may have a different value than its incoming
value, but the method's behavior doesn't depend on the incoming value of
the parameter.

- Testing - - Proving code has an error

- Debugging - - Finding and fixing an error in the code

- Receivers - - Distinguished formal parameters, implicit arguments

- Overloading - - Having methods/variables all with the same name. The
actual constructor is inferred by the program from the argument type.

- .copyFrom() - - Copies values not references

- .newInstance() - - Has the advantage that you don't need to know the
name of any implementation class to call the method

- .compareTo() - - Has all the >,< signs pointing in the same direction

- Primitive types - - Types built-in to Java, refers to an object

- Reference types - - All other types, refers to a location in memory which
points to an object

, - Primitive variable - - Variable of primitive type

- Reference variable - - Variable of reference type

- Reference value - - The memory address of a reference type at which an
object is stored

- Object value - - The actual value of a reference type

- ---> - - We use an arrow instead of "=" to remind ourselves that a variable
is a reference variable

- = - - Copies reference values into other reference variables during
assignment (creating aliasing)

- Uninitialized reference variable - - A reference variable which has been
created but hasn't been assigned a value

- Anonymous reference variable - - A literal, which has an object value but
no name

- Aliasing - - When two or more reference variables point to the same object
(causes problems when one attempts to change the object)

- Parameter passing - - Copies reference values

- Comparing variables - - "==" compares reference values, .equals()
compares object values

- Array - - A group of similar variables all of the same type, a reference type

- Array element - - Each acts like a single variable of the declaration type

- Recursive method - - A method that calls itself

- Implements - - If a class implements an interface then it contains the
method bodies for the behaviors specified in the interface

- Extends - - Can use all methods from the superclass, can override and
modify methods as well

- Override - - Providing a new method body and implementation of a
method inherited from another class, uses @Override annotation

The benefits of buying summaries with Stuvia:

Guaranteed quality through customer reviews

Guaranteed quality through customer reviews

Stuvia customers have reviewed more than 700,000 summaries. This how you know that you are buying the best documents.

Quick and easy check-out

Quick and easy check-out

You can quickly pay through credit card or Stuvia-credit for the summaries. There is no membership needed.

Focus on what matters

Focus on what matters

Your fellow students write the study notes themselves, which is why the documents are always reliable and up-to-date. This ensures you quickly get to the core!

Frequently asked questions

What do I get when I buy this document?

You get a PDF, available immediately after your purchase. The purchased document is accessible anytime, anywhere and indefinitely through your profile.

Satisfaction guarantee: how does it work?

Our satisfaction guarantee ensures that you always find a study document that suits you well. You fill out a form, and our customer service team takes care of the rest.

Who am I buying these notes from?

Stuvia is a marketplace, so you are not buying this document from us, but from seller Nursephil2023. Stuvia facilitates payment to the seller.

Will I be stuck with a subscription?

No, you only buy these notes for $8.49. You're not tied to anything after your purchase.

Can Stuvia be trusted?

4.6 stars on Google & Trustpilot (+1000 reviews)

77529 documents were sold in the last 30 days

Founded in 2010, the go-to place to buy study notes for 14 years now

Start selling
$8.49
  • (0)
  Add to cart