100% satisfaction guarantee Immediately available after payment Both online and in PDF No strings attached
logo-home
CSE 2221 Midterm 1 Exam/92 Questions with verified Answers $12.49   Add to cart

Exam (elaborations)

CSE 2221 Midterm 1 Exam/92 Questions with verified Answers

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

CSE 2221 Midterm 1 Exam/92 Questions with verified Answers

Preview 2 out of 8  pages

  • September 26, 2024
  • 8
  • 2024/2025
  • Exam (elaborations)
  • Questions & answers
  • CSE 2221
  • CSE 2221
avatar-seller
Nursephil2023
CSE 2221 Midterm 1 Exam/92
Questions with verified Answers
When was java developed? by who? - - Devleoped in early 1990s by Sun
Microsystems, now part of Oracle

- What is java based on? - - C/ C++

- Java was originally developed for: - - Interactive TV, but first sucessful in
Internet applications

- What is a Java compiler? - - The compiler checks the source code of a
program in a .java file and if there are no compile-time errors, bytecode for
the program is saved in a .class file

- .java file type? - - Just the source code, this is human readable

- .class file type? - - the bytecode generated by the java compiler is created
in a .class file, it is not human readable

- What is javac? - - The batch-style compiler that is part of the JDK

- Is your program in java run directly on the hardware? - - no, the JVM
executes the .class files by interpreting the bytecode and communicating
with the hardware, so you only need to compile once
Think of JVM as an intermediate between the hardware/OS and MyProg.class

- All java programs must have a method name what? - - public static void
main(String[] args)
- args is by convention

- public keyword means? - - anyone can use this class/method

- final keyword for a class means? - - no one can change the class by using
inheritance

- having a private constructor means? - - No one can create an object of
that class, this type of class is a utility class

- new keyword in java? - - creates a new object to which a variable
references to.

- Why do we use OSU components? - - They help practice best software
engineering practices

, - If you want to write output to a file instead of the console how would you
do that? - - use SimpleWriter1L("file.txt"), instead of leaving () empty as you
would normally

- Character-String literals - - Character-string constatns, aka String literals,
they are enclosed within double quotes, such as "Hello World!"

- String variable - - a variable that stores a character-string values

- variable - - name of a "location" that "stores" a value of a particular type

- type - - name of the set of all possible values that a varible might have, for
example a String might have values like "foo", "Hello World", etc.
int could have values like -1, 4, 18, etc
same applies for double, long, short, etc.

- program variable - - has a particular value at any one time during program
execution, and that value may change at other times

- mathematical varible - - stands for an arbitrary but fixed value

- Program vs mathematical variable? - - Program type has a corresponding
mathematical type that models it, at any given time in the program there is
a mathematical representation of the program variables

- mathematical type of String? - - string of characters

- mathematical type of boolean? - - boolean

- mathematical type of char? - - character

- mathematical type of int? - - integer (about -2 billion to 2 billion)

- mathematical type of double? - - real number between +- 10^+_308, with
15 significant digits in the decimal place

- How many primitive data types in java? - - 8

- How does OSU disginguish program code from mathematics? - - program
is in blue fixed-width, while mathematics is in green fixed-width, italic

- Declaring a variable vs initializing it? - - declaring a variable is just
creating the variable, which provides the name for a location to store its
value and indicate its program type, no value is assigned to it thought
Initializing is when you assign a value to a variable,

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 $12.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
$12.49
  • (0)
  Add to cart