Intro to
Programming
Tony Youssef
Java Programming Head, GDG on
Campus - EUE
Introductions
Who am I?
Who am I?
1. Tony Youssef
2. I am from the United States
3. I only speak English
4. Level 5 CS student
5. 2+ years experience in Java
Email: anthony.youssef23@uol.eue.edu.eg
WhatsApp: +1 (541)-841-2992
Where do we write our
code?
● Any text editor
● Integrated Development
Environment (IDE)
1. IntelliJ by JetBrains
2. VSCode by Microsoft
3. Programiz (Website)
1. IntelliJ by JetBrains
2. VSCode by Microsoft
Recommended IDEs
1. IntelliJ by JetBrains
Basic Syntax
File name
More keywords
Your code goes
here
Keywords
How do we run it?
The simple answer is we can’t.
At least not yet.
What is compiling and how do
we do it?
1. Converting our code into
machine code (byte code
for Java)
1. javac (fileName).java
2. java (fileName)
Our Java file
The compiled
byte code file
Now let’s do something
in our program
Output
Variables
How do we create a variable?
1. (type) (name);
2. (type) (name) = (value);
int
Integer values
1. 1, -1, 0, 1,523,696
2. Ranges from -2,147,483,648
to 2,147,483,647
double
Decimal values
1. 1.5, 2.0, 3.14159265, -12.34
2. Ranges from -1.79*10308
to
1.79*10308
3. Precise up to 15 digits
Number operations
1. +, -, *, /, %
2. +=, -=, ++, --
boolean
Binary values
1. true or false
boolean operations
1. <, >, <=, >=
2. ==, !=, !
3. &&, ||
char
Single character
1. ‘a’, ‘1’, ‘ ’, 97
2. You can think of it as a
character and a number
3. Uses the American
Standard Code for
Information
Interchange(ASCII)
Same value
String
String of characters
1. “Hello”, “123”, “”, “W o r l d”
2. Max length of 2,147,483,467
characters
String operations
1. +, +=
2. .equals()
What should I name
my variable?
Good variable names
1. Should describe the variable
2. camelCase, snake_case, PascalCase
3. Can have numbers, letters,
underscores, and dollar signs ($)
Print more than just
“Hello World!”
How do we get
user input?
Gives us a wide range of
useful tools
Create a variable to
get user inputs
● scan.nextLine();
● scan.nextInt();
● scan.nextDouble();
● scan.nextboolean();
-> String
-> int
-> double
-> boolean
if statements
Loops
for loop while loop
Arrays
What is an array?
● An ordered list of values
What is this error?
Runtime errors
● ArrayIndexOutOfBoundsException
● InputMisMatchException
● StackOverflowError
Compile time errors
1. Invalid syntax
a. Usually typos
Logical errors
Task
● Create a secret 3 digit number and have the user guess what it
is.
○ Get the user’s guess until they get it right
○ Have at least 4 hints
○ Print 1 hint if the answer is incorrect
○ Print the hints in order
○ Print a message saying there are no more hints when all of
them have been shown
○ You can use the number and hints I came up with
■ 628
■ “The last digit is even”
■ “The second digit is the smallest”
■ “The first and the second digits add up to the third
■ “All the digits are even”
More resources
● W3Schools
● GeeksForGeeks
● Oracle (for official Java
documentation)
● StackOverflow (for specific
questions)

More Related Content

PDF
OpenThink Labs Training : Diving into Java, Breaking the Surface
PPTX
Modern_2.pptx for java
PDF
Tdd in practice
PPTX
Tools for the Toolmakers
PPTX
Introduction to Python 01-08-2023.pon by everyone else. . Hence, they must be...
PDF
Tdd is not about testing
PDF
Dutch PHP Conference 2013: Distilled
PPTX
Introduction to java 101
OpenThink Labs Training : Diving into Java, Breaking the Surface
Modern_2.pptx for java
Tdd in practice
Tools for the Toolmakers
Introduction to Python 01-08-2023.pon by everyone else. . Hence, they must be...
Tdd is not about testing
Dutch PHP Conference 2013: Distilled
Introduction to java 101

Similar to Intro to Java Programming - GDG on Campus EUE (20)

PPT
Introduction to Software Development
PDF
Introduction to python
PPTX
How Good of a Java Developer are You?
PDF
Pyramid of-developer-skills
PPTX
Class 8 - Java.pptx
PPTX
Tdd is not about testing (OOP)
PDF
Write codeforhumans
PPTX
Static Code Analysis PHP[tek] 2023
PPTX
Java 101
DOCX
OOP-Chap2.docx
PDF
Python fundamentals - basic | WeiYuan
PDF
Python and Pytorch tutorial and walkthrough
DOCX
Java cheat sheet
PPTX
Coding Checkpoints
PDF
Google Interview Questions By Scholarhat
KEY
Your Own Metric System
PDF
javabasics_ programming development chapter01
PDF
Thinkful - Intro to JavaScript
PDF
Clean Code 2
PDF
The Ring programming language version 1.5.1 book - Part 5 of 180
Introduction to Software Development
Introduction to python
How Good of a Java Developer are You?
Pyramid of-developer-skills
Class 8 - Java.pptx
Tdd is not about testing (OOP)
Write codeforhumans
Static Code Analysis PHP[tek] 2023
Java 101
OOP-Chap2.docx
Python fundamentals - basic | WeiYuan
Python and Pytorch tutorial and walkthrough
Java cheat sheet
Coding Checkpoints
Google Interview Questions By Scholarhat
Your Own Metric System
javabasics_ programming development chapter01
Thinkful - Intro to JavaScript
Clean Code 2
The Ring programming language version 1.5.1 book - Part 5 of 180
Ad

More from Google Developer Group On Campus European Universities in Egypt (7)

PDF
Introduction to Typescript - GDG On Campus EUE
PDF
LinkedIn for Developers: Building your LinkedIn Profile - GDG on Campus EUE
PPTX
Introduction to Internet of Things (IoT) - GDG on Campus European Universitie...
PDF
Introduction to Artificial Intelligence with Python, CS50 Approach - GDG on C...
PDF
Intro to AI - GDG on Campus European Universities in Egypt
PDF
Info Session - GDG on Campus European Universities in Egypt
PDF
Intro to Backend Development - GDG on Campus EUE
Introduction to Typescript - GDG On Campus EUE
LinkedIn for Developers: Building your LinkedIn Profile - GDG on Campus EUE
Introduction to Internet of Things (IoT) - GDG on Campus European Universitie...
Introduction to Artificial Intelligence with Python, CS50 Approach - GDG on C...
Intro to AI - GDG on Campus European Universities in Egypt
Info Session - GDG on Campus European Universities in Egypt
Intro to Backend Development - GDG on Campus EUE
Ad

Recently uploaded (20)

PDF
Consumable AI The What, Why & How for Small Teams.pdf
PDF
Hindi spoken digit analysis for native and non-native speakers
PPT
Module 1.ppt Iot fundamentals and Architecture
PDF
Hybrid horned lizard optimization algorithm-aquila optimizer for DC motor
PPT
Galois Field Theory of Risk: A Perspective, Protocol, and Mathematical Backgr...
PDF
Abstractive summarization using multilingual text-to-text transfer transforme...
PDF
A contest of sentiment analysis: k-nearest neighbor versus neural network
PPTX
Microsoft Excel 365/2024 Beginner's training
PPTX
MicrosoftCybserSecurityReferenceArchitecture-April-2025.pptx
PDF
Zenith AI: Advanced Artificial Intelligence
PDF
Enhancing emotion recognition model for a student engagement use case through...
PPTX
Final SEM Unit 1 for mit wpu at pune .pptx
PDF
CloudStack 4.21: First Look Webinar slides
PPTX
Configure Apache Mutual Authentication
PDF
Taming the Chaos: How to Turn Unstructured Data into Decisions
PDF
Developing a website for English-speaking practice to English as a foreign la...
PDF
Architecture types and enterprise applications.pdf
PDF
NewMind AI Weekly Chronicles – August ’25 Week III
PDF
Flame analysis and combustion estimation using large language and vision assi...
PPTX
Chapter 5: Probability Theory and Statistics
Consumable AI The What, Why & How for Small Teams.pdf
Hindi spoken digit analysis for native and non-native speakers
Module 1.ppt Iot fundamentals and Architecture
Hybrid horned lizard optimization algorithm-aquila optimizer for DC motor
Galois Field Theory of Risk: A Perspective, Protocol, and Mathematical Backgr...
Abstractive summarization using multilingual text-to-text transfer transforme...
A contest of sentiment analysis: k-nearest neighbor versus neural network
Microsoft Excel 365/2024 Beginner's training
MicrosoftCybserSecurityReferenceArchitecture-April-2025.pptx
Zenith AI: Advanced Artificial Intelligence
Enhancing emotion recognition model for a student engagement use case through...
Final SEM Unit 1 for mit wpu at pune .pptx
CloudStack 4.21: First Look Webinar slides
Configure Apache Mutual Authentication
Taming the Chaos: How to Turn Unstructured Data into Decisions
Developing a website for English-speaking practice to English as a foreign la...
Architecture types and enterprise applications.pdf
NewMind AI Weekly Chronicles – August ’25 Week III
Flame analysis and combustion estimation using large language and vision assi...
Chapter 5: Probability Theory and Statistics

Intro to Java Programming - GDG on Campus EUE