Chapter 1 - Intro to Computers, Programs, and Java Flashcards

1
Q

Intro to Computers, Programs, and Java

Why is Java platform independent?

A

The JVM can be installed on most platforms, and Java source code will be translated by the specific JVM to the platforms machine language

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Intro to Computers, Programs, and Java

What is important for the Java source file names, in relation to class names?

A

The source file name must match the public class name in the program

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Intro to Computers, Programs, and Java

What extension name does Java source files have?

A

.java

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Intro to Computers, Programs, and Java

When does a file name end with .class?

A

When classes are compiled into byte code, the new file has the .class extension

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Intro to Computers, Programs, and Java

What two types of import are there?

A

Specific import and wildcard import. Specific imports single classes, while wildcard imports all classes in a package

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Intro to Computers, Programs, and Java

What are the three categories of errors?

A

Syntax errors, runtime errors, and logic errors

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Intro to Computers, Programs, and Java

__ is the brain of the computer.

A

The CPU

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Intro to Computers, Programs, and Java

The speed of the CPU is measured in __

A

Hertz. Megahertz, or more commonly today, gigahertz

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Intro to Computers, Programs, and Java

Why does the computer use zeros and ones?

A

Because digital devices have two stable states and it is natural to use one state for 0 and the other for 1

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Intro to Computers, Programs, and Java

One byte has __ bits

A

8

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Intro to Computers, Programs, and Java

The computer can only execute code in ___ language

A

Machine language

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Intro to Computers, Programs, and Java

___ translate high-level code into machine code

A

Compilers

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Intro to Computers, Programs, and Java

Java was developed by ___

A

Sun Microsystems

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Intro to Computers, Programs, and Java

Java ___ can run from a web browser

A

Java applets

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Intro to Computers, Programs, and Java

Which of these are object-oriented programming languages?

Java, C++, C, C#, Pascal

A

Java, C++ and C#

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Intro to Computers, Programs, and Java

What is the ‘Java language specification’?

A

It is a technical definition of the language that includes the syntax and semantics of the Java programming language

17
Q

Intro to Computers, Programs, and Java

What is the ‘Java API’?

A

The Java API (application programming interface) contains predefined classes and interfaces for developing Java programs

18
Q

Intro to Computers, Programs, and Java

What is the ‘Java JDK’?

A

The Java JDK (Java development kit) consists of a set of separate programs for developing and testing Java programs, each of which is invoked from a command line

19
Q

Intro to Computers, Programs, and Java

What is a ‘Java IDE’?

A

A Java IDE provides an integrated development environment (IDE) for rapidly developing Java programs. Editing, compiling, building, debugging, and online help are integrated in one graphical user interface