
String Methods in Java
Presentation
•
Computers
•
10th Grade
•
Medium
Lisa Donlan
Used 10+ times
FREE Resource
15 Slides • 10 Questions
1
2
3
4
5
Multiple Choice
What is the output?
String word1 = "Hello";
String word2 = "hello";
System.out.println(word1.equals(word2);
true
false
6
7
8
9
Multiple Choice
What is the output?
String word1 = "Day";
System.out.println(word1.length( ));
1
2
3
4
10
Multiple Choice
What is the output?
String word1 = "Day Old";
System.out.println(word1.length( ));
3
5
6
7
11
12
Multiple Choice
What is the output?
String word1 = "Happy Days";
System.out.println(word1.charAt(0);
D
H
Happy
Days
13
Multiple Choice
What is the output?
String word1 = "Happy Days";
System.out.println(word1.charAt(2);
H
a
p
y
14
15
16
17
Multiple Choice
What is the output?
String word1 = "Happy Days";
System.out.println(word1.substring(0,4);
Happy
Days
Hap
Happ
18
Multiple Choice
What is the output?
String word1 = "Happy Days";
System.out.println(word1.substring(4,9);
y Days
Day
Days
y Day
19
20
Multiple Choice
What is the ouput?
String word1 = "Hello";
String word2 = "hello";
System.out.println(word1.equals(word2);
System.out.println(word1.equalsIgnoreCase(word2);
true
true
true
false
false
true
false
false
21
String str = "class";
What does str.length( ) equal?
22
String str = "class";
What is the output?
23
Multiple Choice
What is the output?
String word1 = "stressful";
System.out.println(word1.substring(3));
essful
e
r
ressful
24
Overloading
substring(int) vs. substring(int, int)
This is an example of overloading. Java is smart enough to know that when you only use one integer, then give the rest of the string.
If you use two integers, then you are only getting part of the string.
25
Open Ended
What are 3 things you learned today?
Show answer
Auto Play
Slide 1 / 25
SLIDE
Similar Resources on Wayground
19 questions
Informatika TJKT
Presentation
•
10th Grade
21 questions
Computer Basics
Presentation
•
9th - 10th Grade
19 questions
BIOS - Kelas X TKJ
Presentation
•
10th Grade
18 questions
O que são varáveis
Presentation
•
10th Grade
21 questions
Data Types lesson
Presentation
•
10th Grade
23 questions
The Computer
Presentation
•
10th Grade
22 questions
Input & Output devices
Presentation
•
9th - 10th Grade
19 questions
Kelas X BAB 2 - 3 Membuat Flow Chart
Presentation
•
10th Grade
Popular Resources on Wayground
10 questions
GPA Lesson
Presentation
•
9th - 12th Grade
7 questions
Albert Einstein
Quiz
•
3rd Grade
31 questions
Bridge A Review
Quiz
•
3rd Grade
6 questions
Blue Sue and Red Ruth
Quiz
•
3rd Grade
8 questions
(Day12 HW) Inverse Trig Ratios
Quiz
•
9th Grade
20 questions
Summer Geometry QUIZ (Week3)
Quiz
•
9th Grade
16 questions
Theme Practice
Quiz
•
7th Grade
20 questions
Taxes
Quiz
•
9th - 12th Grade
Discover more resources for Computers
10 questions
GPA Lesson
Presentation
•
9th - 12th Grade
20 questions
Taxes
Quiz
•
9th - 12th Grade
16 questions
Translations and Reflections
Quiz
•
9th - 10th Grade
17 questions
High School Survival Guide
Presentation
•
9th - 12th Grade
20 questions
Banking
Quiz
•
9th - 12th Grade
20 questions
Budgeting
Quiz
•
9th - 12th Grade