100% satisfaction guarantee Immediately available after payment Both online and in PDF No strings attached
logo-home
CIS 3145 MidTerm Exam Review Questions With Complete Solutions $10.49   Add to cart

Exam (elaborations)

CIS 3145 MidTerm Exam Review Questions With Complete Solutions

 10 views  0 purchase
  • Course
  • CIS 3145
  • Institution
  • CIS 3145

CIS 3145 MidTerm Exam Review Questions With Complete Solutions What is the Java Programming Language? - Correct Answer It was released in 1995 as a part of Sun Microsystems' Java platform. The language has developed much of its syntax from C and C++. Java applications are usually compiled to bytec...

[Show more]

Preview 3 out of 16  pages

  • September 18, 2024
  • 16
  • 2024/2025
  • Exam (elaborations)
  • Questions & answers
  • CIS 3145
  • CIS 3145
avatar-seller
Winfred
CIS 3145 MidTerm Exam Review Questions With
Complete Solutions
What is the Java Programming Language? - Correct Answer It was released in 1995 as a part of Sun
Microsystems' Java platform. The language has developed much of its syntax from C and C++. Java
applications are usually compiled to bytecode (class file) that can run on any Java Virtual Machine
(JVM). Java is currently one of the most popular programming languages being used.



How does the Java language compare to other languages? - Correct Answer Java was made so its
applications can be run on any computer platform without needing to be compiled for each platform.
Designed to automatically handle many operations involving the allocation and de-allocation of
memory.



How is a Java application compiled? - Correct Answer The java compiler compiles the source code
into a format known as Java Byte-codes, those byte-codes can be run on any platform that has a Java
Runtime Environment or JRE. Than using a JVM (Java Virtual Machine) it translates the Bytecodes
into native code that can be understood.



What is the IDE? - Correct Answer Integrated Development Environment. Provides features that can
make developing Java applications considerably easier. These code developers include Netbeans,
Eclipse, and Android Studio.



How does Netbeans Work? - Correct Answer



**CHAPTER 2** - Correct Answer



How do you write code to create Class? - Correct Answer public class NumberGameApp;



What code creates main method? - Correct Answer public static void main(String[]args) {



}



What code creates a statement - Correct Answer package murach.test;



What code creates a java comment - Correct Answer // single line comment

<!-- Multiple Line Comment -->

,What is an identifier in the Java language? - Correct Answer In Java programming language, an
identifier is a name given to a variable, class or method. Identifiers start with a letter, underscore(_)
or dollar sign ($).



What are the rules for naming a class? Recommendations? - Correct Answer Common coding
convention is to start the class name and every word within that name with a capital letter. Letters
and Digits only.

Examples: CodeTesterApp, NumberGuessingGame, and StudentClass



What are the rules and recommendations for naming variables? - Correct Answer All variables have
to be initialized with the fist letter of the first word lowercase and any word after that with no space
and capitalized. Also, avoid abbreviations

Example: newCust, productPrice, maxQuantity



What is the syntax for declaring a primitive variable? - Correct Answer There are eight primitive data
types that are used for storing values in memory.

boolean

char

byte

float

void

short

double

int

long

Int and double are the two most common.



What is an assignment statement and how is it used with arithmetic expressions? - Correct Answer
An assignment statement assigns a value to a variable that is already declared. This value can be a
literal value, another variable, or an expression.



How is a string variable different from primitive variables? - Correct Answer Primitive types are the
basic types of data

, byte, short, int, long, float, double, boolean, char



primitive variables store primitive values

reference types are any instantiable class as well as arrays

String, Scanner, Random, Die, int[], String[], etc.

reference variables store addresses



What objects are used to get input and send output to the console? - Correct Answer Getting input

int number = Integer.parseInt( input );



Sending output

System.out.println("Output to console")



**CHAPTER 3** - Correct Answer



What code is used to create a class? - Correct Answer java.lang.String

java.lang.Integer

java.lang.Double

java.util.Scanner

java.text.NumberFormat



What code is used to create an object? - Correct Answer new ClassName(arguments);

When creating an object, you are creating an instance of the class. Then, use the methods of the
class by calling them from the object.



What are methods? - Correct Answer A method is a block of code that preforms an action. A method
typically returns a value or object that you can assign to a variable.



What is a static method? - Correct Answer A static method, similar to regular methods, but you can
call them directly from the class without creating an object from the class.

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 Winfred. Stuvia facilitates payment to the seller.

Will I be stuck with a subscription?

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

Can Stuvia be trusted?

4.6 stars on Google & Trustpilot (+1000 reviews)

73918 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
$10.49
  • (0)
  Add to cart