0% found this document useful (0 votes)
2 views3 pages

Tutorial 1

The document is a tutorial on programming, specifically focusing on Java and its features, including the roles of compilers and the Java Virtual Machine (JVM). It includes exercises that cover definitions, classifications, explanations, comparisons, analyses, evaluations, and reflective questions related to programming concepts and Java's characteristics. The tutorial aims to enhance understanding and application of programming principles and practices.
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views3 pages

Tutorial 1

The document is a tutorial on programming, specifically focusing on Java and its features, including the roles of compilers and the Java Virtual Machine (JVM). It includes exercises that cover definitions, classifications, explanations, comparisons, analyses, evaluations, and reflective questions related to programming concepts and Java's characteristics. The tutorial aims to enhance understanding and application of programming principles and practices.
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Tutorial 1: Introduction to Programming

PART A – Remember & Understand (C1–C2)


Exercise A1: Define / Identify / State
1. Define programming language.
2. Define Java as a programming language.
3. State TWO features that make Java a high-level language.
4. Identify the meaning of a compiler.
5. State the role of the Java Virtual Machine (JVM).
6. State at least TWO differences between an interpreter and a compiler.
7. Identify the latest JDK version you are familiar with.

Exercise A2: Classify / Distinguish / Explain


Classify each of the following as Compiler or Interpreter and justify your answer:
1. Converts the whole program into machine code before execution.
2. Executes a program line by line.
3. Produces a .class file in Java.
4. Used for scripting languages like Python.

PART B – Understand & Explain (C2)


Exercise B1: Explain / Describe
1. Explain why Java is called a platform-independent language.
2. Describe the difference between high-level and low-level programming languages.
3. Explain the purpose of the JVM in executing Java programs.
4. Describe the role of the compiler in the Java programming process.
5. Explain why understanding programming paradigms is important for software
development.
PART C – Apply & Differentiate (C3–C4)
Exercise C1: Differentiate / Compare
Differentiate between the following concepts using a comparison table:
• Compiler vs Interpreter
• Procedural vs Object-Oriented Programming (OOP)
• High-level language vs Low-level language
• JDK vs JVM
Exercise C2: Illustrate / Explain
1. Illustrate the steps involved in the Java programming process (write code → compile
→ execute).
2. Explain why OOP paradigms improve code reusability compared to procedural
paradigms.

PART D – Analyze (C4)


Exercise D1: Analyze / Determine / Justify
Case: A Java program throws runtime errors because variables are used before initialization.
1. Analyze the impact of this error on program execution.
2. Determine whether this error is detected by the compiler or JVM.
3. Justify why following the correct programming process could have prevented this
error.
Exercise D2: Analyze / Distinguish
Scenario: A developer reviews the Java code for style and logic errors before running it.
Later, the program is executed and output errors are found.
1. Distinguish which activity represents static checking and which represents dynamic
checking.
2. Analyze why both code review and program execution are important in Java
development.
PART E – Evaluate (C5)
Exercise E1: Evaluate / Justify
1. Evaluate the statement: “Java programs are slower than C programs because of the
JVM.”
2. Justify your answer using software portability and performance perspectives.
Exercise E2: Assess / Argue
1. Assess the importance of understanding Java history and versions for a developer.
2. Argue whether learning multiple programming paradigms is essential for Java
programmers.

PART F – Reflection (C3–C5)


Reflective Questions
1. Reflect on how using Java OOP principles improves program maintainability.
2. Evaluate which Java feature (JVM, high-level syntax, or platform independence) you
find most important and explain why.
3. Justify why following the structured programming process reduces programming
errors and risks.
1.

You might also like