ITB 102-(Computer Programming 1)

4.0(1)
studied byStudied by 11 people
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/35

encourage image

There's no tags or description

Looks like no tags are added yet.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

36 Terms

1
New cards

Java

  • is a popular programming language created in 1995.

  • it is owned by Oracle, and more than 3 bilion devices run using this language.

2
New cards

Java Syntax

the name of the java file must be match the class name. When saving the file, saveit using the class name and add “.java” at the end.

3
New cards

Main Method

is required and you will see it in every Java Programming. Any code inside this will be executed.

4
New cards

System.out.print()

inside the main() method, we can use this method to print a line if text to the screen

5
New cards

Double Quotes

when your working with a text, it must be wrapped around with “ “.

6
New cards

Print() Method

this also a print() method which is similar to println(). the only difference is that it does not insert a new line at the end of the output

7
New cards

Print Numbers

you can also use println() method to print numbers. However, unlike text, we don't put it inside “ “.

8
New cards

Java Variable

string, int, float, char, boolean

9
New cards

String

store texts

10
New cards

int

store integers

11
New cards

float()

stores floating point numbers

12
New cards

char()

store a single character

13
New cards

boolean()

stores a value with two states: true or false

14
New cards

Identifiers

all java Variable must be identified with unique names. These unique names are called ____.

15
New cards

Primitive and Non-Primitive Data Type

Data Types

16
New cards

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

Variables under Primitive Data Type

17
New cards

String, Array, Classes

Variables under Non-Primitive Data Type

18
New cards
  • Yes / No

  • On / Off

  • True / False

Boolean Type

19
New cards

Non-Primitive Data Type

are called reference type because they refer to objects.

20
New cards

Addition, Subtraction, Multiplication, Division, Modulus, Increment, Decrement

Arithmetic Operators

21
New cards

+

Operation for Addition

22
New cards

*

Operation for Multiplication

23
New cards

/

Operation for Division

24
New cards

%

Operation for Modulus

25
New cards

++

Operation for Increment

26
New cards

- -

Operation for Decrement

27
New cards

Single-Line Comment

starts with the forward dash ( // )

28
New cards

Multiple - Line Comments

starts with ( /* ) and ends with ( /* )

29
New cards

Java Operators

are used to perform operation on variables and values

30
New cards

Arithmetic Operators

Are use to perform common mathematical equations

31
New cards

Assignment Operators

are use to assign values to a variables

32
New cards

Comparison Operation

are used to compare values ( or variables )

33
New cards

Logical Operators

are use to determine the logic between variables and value

34
New cards

Java String

a variable contains a collection of characters surrounded by double quotes.

35
New cards

String Length

in java, is actually an object which contains method that can perform certain operations onnstrings

36
New cards

More String Method

there are many string methods available for example : toUpper() and toLower()