CourseGenix
Explore
Toggle theme
Sign In
Java Fundamentals
5 Units
21 Lessons
Unit 1
Basics
Introduction to Java Syntax and Hello World Program
Understanding Variables and Data Types in Java
Basic Operators in Java
Real-World Project: Building a Simple Calculator in Java
Input and Output Operations in Java
Unit 2
Control Structures and Loops
Real-World Project: Creating a Number Guessing Game with Loops
Implementing For and While Loops in Java
Using If-Else and Switch Statements in Java
Unit 3
Methods and Functions
Defining and Calling Methods in Java
Working with Parameters and Return Types in Java Methods
Method Overloading in Java
Real-World Project: Developing a String Utility Methods Library
Unit 4
Object-Oriented Programming
Creating Classes and Objects in Java
Inheritance and Polymorphism in Java
Encapsulation and Abstraction in Java
Using Interfaces and Abstract Classes in Java
Real-World Project: Designing a Basic Inventory Management System
Unit 5
Exception Handling and File I/O
Handling Exceptions with Try-Catch in Java
Creating and Using Custom Exceptions in Java
Reading and Writing Files in Java
Real-World Project: Building a Simple Text File Processor
Unit 1
•
Chapter 3
Basic Operators in Java
Summary
No summary available for this chapter.
Concept Check
0/10
What is the result of ~5 in Java?
6
-6
-6
-5
For int i=10, what is i after i += i++ * 2?
31
20
31
30
What is the output of System.out.println(5 / 2)?
3
2.5
2
2
Among *, +, =, which has highest precedence?
*
*
+
=
For boolean x=true, y=false, what is x ^ y?
false
true
null
true
What is the result of 5 + 3 * 2 in Java?
11
8
16
11 due to multiplication precedence
What does the bitwise AND operator & do with 12 & 5?
4 as binary intersection
7
17
4
What is the value of i after i = 10; j = ++i;?
12
11 after pre-increment
10
11
What is the outcome of true && false || true?
error
true from logical evaluation
false
true
What does the += operator do in x += y;?
x = y + x
x = x - y
x = x + y
Adds y to x and assigns
10 questions remaining
Previous
Understanding Variables and Data Types in Java
Next
Real-World Project: Building a Simple Calculator in Java