Use LEFT and RIGHT arrow keys to navigate between flashcards;
Use UP and DOWN arrow keys to flip the card;
H to show hint;
A reads text to speech;
33 Cards in this Set
- Front
- Back
Java is _________ to Java Bytecode, not ______.
|
compiled, interpreted
|
|
___________ is interpreted when the program runs
|
Bytecode
|
|
________ is interpreted, so it translates as it runs
|
Python
|
|
_________ _________ _________ is a library of code that you can use in Java programs
|
Java Application Programming Interface
|
|
________ are types already built into Java and they turn purple in JGRASP.
|
Primitives
|
|
What are integer types in the order of their size?
|
Byte, short, int, long
|
|
What are floating types in the order of size?
|
float, double
|
|
Variables must start with a _________
|
letter, $, or underscore
|
|
After the first letter, a character name can be
|
a number, letter, $, or underscore
|
|
_______ are indicated by single quotes
|
characters
|
|
Each character maps to a number between __ and ___
|
0 and 255
|
|
What does 'a' correspond to?
|
97
|
|
What does 'A' correspond to?
|
65
|
|
What does '0' correspond to?
|
48
|
|
What is the order of operation for arithmetic?
|
- ()
- -(negative) - *, / , % - + , - - = |
|
_ gives you the remainder when dividing two numbers
|
%
|
|
How would you find the ones digit and the tens digit of a number respectively?
|
ones digit: mod by 10
tens digit: divide by 10 then mod by 10 |
|
Objects are _________ of classes
|
instantiations
|
|
You can call _______ on objects
|
Methods
|
|
Java saves the ______ in memory of where the Object's data is
|
location
|
|
The _____ and the _______ class provide static methods that you can call with the class name. You cannot instantiate them.
|
Math, Character
|
|
Strings are _____, not primitive types. They can be indicated by _______ ________
|
objects;
double quotes |
|
What are methods of Strings?
|
String.charAt()
String.length() String.toUpperCase() String.toLowerCase() String.substring() |
|
What are the escape characters?
|
\t new tab
\n new line \\ |
|
If you need to compare Strings never use _____. What should you use instead?
|
==
if (s1.equals(s2)) System.out.println("They are the same") |
|
What should you put to convert a String to a double or an int?
|
Double.parseDouble("32.5")
Integer.parseInt("5") |
|
What should you do to convert a number to a string
|
int a = 7
String s = a + "" ; |
|
How do you initialize a scanner?
|
Scanner kb = new Scanner(System.in)
|
|
What are some methods of scanner?
|
s.hasNext()
s.nextInt() s.next() s.nextDouble() s.next().charAt(0) |
|
_______ command allows you to format a print statement in very specific ways
|
printf
|
|
What are some imports you would do?
|
import java.util.Scanner
|
|
What are the class imports?
|
public class Myclass {
|
|
What are the main method line?
|
public static void main(String[] args)
|