0% found this document useful (0 votes)
137 views

Java Prog Sem-3

The document provides a lesson plan for a Java Programming Lab course. It outlines the course objectives, outcomes, syllabus, and two experiments covering fundamental Java concepts like classes, objects, arrays, and control structures as well as more advanced topics like inheritance, interfaces, exceptions, and GUI programming.

Uploaded by

Nitish Jha
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
137 views

Java Prog Sem-3

The document provides a lesson plan for a Java Programming Lab course. It outlines the course objectives, outcomes, syllabus, and two experiments covering fundamental Java concepts like classes, objects, arrays, and control structures as well as more advanced topics like inheritance, interfaces, exceptions, and GUI programming.

Uploaded by

Nitish Jha
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 23

FR.

Conceicao Rodrigues College Of Engineering


Father Agnel Ashram, Bandstand, Bandra-west, Mumbai-50
Department of Information Technology

B.E. (IT) (semester III) (2018-2019)


Lesson Plan:
Subject: Java Programming Lab (ITL304) Credit-2

Course Code Course Name Theory Practical Tutorial Theory TW/Practical Tutorial Total
Java
ITL304 Programming -- 2+2* -- -- 2 -- 2
Lab

Examination Scheme

Theory Marks
Course Internal assessment
Course Name Term Oral & Practical
Code End Total
Avg. of Sem. Work
Test1 Test 2 two Exam
Tests

ITL304 Java
Programming -- -- -- -- 50 50 100
Lab

* 2 hours shown as practical’s to be taken class wise lecture and other 2 hours to be taken as batch
wise practical’s in Lab.

Lab Objectives: Students will try:

1. To understand how to design, implement, test, debug, and document programs that use basic
data types and computation, simple I/O, conditional and control structures, string handling and
functions.
2. To understand the importance of Classes & objects along with constructors, Arrays and Vectors.
3. Discuss the principles of inheritance, interface and packages and demonstrate though problem
analysis assignments how they relate to the design of methods, abstract classes and interfaces and
packages.
4. To understand importance of Multi-threading & different exception handling mechanisms.
5. To learn experience of designing, implementing, testing, and debugging graphical user interfaces
in Java using applet and AWT that respond to different user events.
6. To understand Java Swings for designing GUI applications based on MVC architecture.

Lab Outcomes: Upon Completion of the course the learner should be able to:

1. Implement Object Oriented programming concept using basic syntaxes of control


Structures, strings and function for developing skills of logic building activity.
2. Identify classes, objects, members of a class and the relationships among them needed for a
finding the solution to specific problem
3. Demonstrates how to achieve reusability using inheritance, interfaces and packages
and describes faster application development can be achieved.
4. Demonstrate understanding and use of different exception handling mechanisms and
concept of multithreading for robust faster and efficient application development.
5. Identify and describe common abstract user interface components to design GUI in
Java using Applet & AWT along with response to events
6. Identify, Design & develop complex Graphical user interfaces using principal Java Swing
classes based on MVC architecture

Hardware Requirements Software Requirements Other Requirements

PC With Following 1. Windows or Linux Desktop OS 1. Internet Connection for


Configuration 2. JDK 1.8 or higher installing additional packages
1. Intel PIV Processor 3. Notepad ++ if required
2. 2 GB RAM 4. JAVA IDEs like Netbeans or
3. 500 GB Harddisk Eclipse
4. Network interface card

Detailed Syllabus:

Sr. LO
Module Detailed Contents Hours
No. Mapping

1) Theory

Overview of procedure and object oriented


Programming, Java Designing Goals, Features of Java
Language.

Introduction to the principles of object-oriented


programming: Classes, Objects, Abstraction,
Encapsulation, Inheritance, Polymorphism,

Fundamental Keywords, Data types, Variables, Operators,


of Java Expressions, Types of variables and methods. 12 LO 1
Programming
Control Statements: If Statement, If-else, Nested LO 2
if, switch Statement, break, continue. Iteration
Statements: for loop, while loop, and do-while loop.

Experiment 1:

(Perform any three programs that covers Classes,


Methods, Control structures and Looping statements)

i) Write a Java program to understand how to


accept input using Scanner or
BufferedReader and print output using
System.out.println statement.
ii) Write a Java program to display the
default value of all primitive data types
in Java.
iii) Write a Java program that prints all real
solutions to the quadratic equation
ax2+bx+c = 0. Read in a, b, c and use the
quadratic formula. If the discriminate b2-
4ac is negative, display a message stating
that there are no real solutions.
iv) Write a java program to test whether
string is palindrome or not

v) Write a java program to count number


of alphabets, digits, special symbols,
blank spaces and words from the given
sentence.
vi) Write a java program to count number of
vowels and consonants from the given
strings.
vii) Write a Menu driven program in java to
implement simple banking application. Application
should read the customer name, account number,
initial balance, rate of interest, contact number and
address field etc. Application should have following
methods.
1. createAccount()

2. deposit()

3. withdraw()

4. computeInterest()

5. displayBalance()

viii) Write a menu driven Java program which will


read a number and should implement the following
methods

1. factorial()

2. reverse()

3. testArmstrong()

4. testPalindrome()

5. testPrime()

6. fibonacciSeries()

ix) Write a Java program to demonstrate Method


overloading

2) Theory

Classes & Objects: Class Fundamentals:


Assigning Object Reference Variables, Passing
parameters to Methods and Returning parameters from
the methods, Nested and Inner Classes.

Constructors: Parameterized Constructors,


finalize( ) Method, Method overloading, Constructors
Classes,
overloading, Recursion, Command-Line Arguments.
Objects,
LO 1
Arrays and Wrapper classes, Java.util.Scanner, Java. 12
Recursion io.BufferedReader, Java.io.DataInputStream, LO 2
Java.io.DataOutputStream and String Buffer classes and
String functions.

Arrays & Vectors: One Dimensional arrays, Two


Dimensional array, Irregular arrays, dynamic arrays,
Array List and Array of Object.

Experiment 2

(Perform any Five programs that covers Classes &


objects, Constructors, Command Line Arguments,
Arrays/Vectors & recursions)

i) Write a java program to demonstrate


Constructors, Parameterized Constructors
and Constructor Overloading
ii) Write a java program to demonstrate

Command Line Arguments

iii) Write a java program to demonstrate String

Functions

iv) Write a java program to demonstrate Array

and Vectors operations

v) Write a java programs to add n strings in a


vector array. Input new string and
check whether it is present in the vector. If it is
present delete it otherwise add it to the vector.
vi) Write a java programs to test whether the
given element is present in the vector
array.

vii) Write a java programs to find frequency of

a element in the given Vector array.

viii) Write a java programs to add n strings in a

vector array. Input new string and check whether it

is present in the vector. If it is present delete it

otherwise add it to the vector.

ix) Write menu driven program to implement

recursive functions for following

tasks.
a) To find GCD and LCM
b) To find XY
c) To print n Fibonacci numbers
d) To find reverse of number
e) To 1+2+3+4+……..+(n-1)+n
x) Write the Menu driven program to perform
a) Addition of two matrices of order m*n and
p*q
b) Multiplication of two matrices of order m*n
and p*q
c) Transpose of matrix of order m*n
d) addition of diagonal and non-diagonal
elements

3) Theory

Inheritance Basics, , Types of Inheritance in Java,


Concept of Super and sub class, inheriting Data
members and Methods, Role of Constructors in
inheritance, Making methods and classes final ,
Method overriding, Dynamic Method Dispatch,
Abstract classes and methods

Defining an interface, extending interfaces ,


implementing interfaces, accessing implementations

Inheritance, through interface references, Interfaces vs. Abstract


Interface and classes. 08 LO 3
Packages Packages – Steps for defining, creating and
accessing a Package, importing packages,Making JAR
Files for Library Packages, java.util.Vector

Experiment 3

(Perform any Two programs that covers Inheritance,


interfaces and packages)

i) Write a java programs to demonstrate


hierarchical inheritance
ii) Write a java program to demonstrate extending
& implementing Interfaces
iii) Write a java program to demonstrate Modules
and packages
iv) Write a java program to create user defined
packages

4) Theory:

Exception handling Mechanism: try, catch,


throw, throws and finally.

Multithreading: Need of Multithreading , Java


thread Model, thread Life-Cycle, thread class
Methods, Implementing Runnable, Extending thread,
Synchronizing threads, synchronized Statement,
Critical Factor in Thread –Deadlock.

Experiment 4

(Perform any Two programs that covers Exception


Exception Handling & Multithreading)
Handling and
i) Write java programs to demonstrate Exception
Multithreading 06
handling using try, catch, throw, throws and finally
statements.
LO3
ii) Write a Java Program to input the data through
command Line and Find out total valid and in-valid LO 4

integers. (Hint: use exception handling).


iii) Write a Java Program to calculate the Result.
Result should consist of name, seatno, date, center
number and marks of semester three exam. Create a
User Defined Exception class
MarksOutOfBoundsException, If Entered marks of
any subject is greater than 100 or less than 0, and
then program should create a user defined Exception
of type MarksOutOfBoundsException and must have
a provision to handle it.
iv) Write java program to create a user defined
Exception class known as
PayOutOfBoundsException. Organization does not
offer basic salary less than 8000. If entered salary is
less than 8000 then program should create an
Exception of Type PayOutOfBoundsException.
Program should calculate gross salary by considering
salary parameters such as DA, HRA, CA, TA,
Professional tax, TDS, PF.. etc

v) Write java programs to create user defined threads


by extending thread class and by implementing
runnable.

vi) Write java program to print Table of Five, Seven


and Thirteen using Multithreading (Use Thread class
for the implementation) .

vii) Write a java program to print first 20 prime


numbers and 15 Fibonacci numbers by creating two
child threads and also print the total time taken by
each thread for the execution.

viii) Write a java program to implement use of nested


try-catch concept using appropriate example.

ix) Write java program to create the child thread.


Comment on the execution of main and Child
Thread.
x) Write java program to implement the concept of
Thread Synchronization

xi) Write a Java program to identify whether inputted


data is byte/short/int/long/float/double/String/char
type. (Use Exception Handling)

5) Applet 5.1 Applet: Applet fundamentals, Applet lifecycle, LO3


Programming, Creating applet, paint method Applet tag, Applet 10
class methods. LO4
GUI
development Designing Graphical User Interfaces in Java, LO 5
using AWT Components and Containers, Basics of Components,
and Event Using Containers, Layout Managers, AWT
handling Components, Adding a Menu to Window, Extending
GUI Features

Event-Driven Programming in Java, Event-


Handling Process, Event- Handling Mechanism,
Delegation Model of Event Handling, Event
Classes, Event Sources, Event Listeners, Adapter
Classes as Helper Classes in Event Handling.

Experiment 5

(Perform any Three programs that covers Applet


Programming, GUI development using AWT and
Event handling)

i) Write java program to draw the house on an applet.

ii) On Applet: Take a Login and Password from the


user and display it on the third Text Field which
appears only on clicking OK button and clear
both the Text Fields on clicking RESET button
Perform same using AWT and Swings as well.

iii) Write java program to create an advertisement


banner on an applet using multithreading

iv) Write java program to create a registration form


using AWT.

v) Write a Java program to demonstrate the use of


AWT components namely buttons,labels, text boxes,
lists/combos, menus with event handling.
vi) Write a java program to store personal telephone
directory in such a way that when user hits a
character, the names which starts with the character
and telephone numbers should appear.

6) Theory

6.1 Introducing Swing: AWT vs Swings,


Components and Containers, Swing Packages, A
Simple Swing Application, Painting in Swing,
Designing Swing GUI Application using
Buttons,JLabels, Checkboxes, Radio Buttons,
JScrollPane, JList, JComboBox, Trees, Tables Scroll
pane Menus and Toolbars

Experiment 6

(Perform any one programs that covers concept of


Swings) LO4
Java Swings 06
i) Write a Java program to implement Swing LO 6
components namely Buttons, ,JLabels, Checkboxes,
Radio Buttons, JScrollPane, JList, JComboBox,
Trees, Tables Scroll pane Menus and Toolbars to
design interactive GUI.

ii) Write a program to create a window with four


text fields for the name, street, city and pincode with
suitable labels. Also windows contains a button
MyInfo. When the user types the name, his street,
city and pincode and then clicks the button, the
types details must appear in Arial Font with Size 32,
Italics.

Textbook Books:

1. Herbert Schildt, “Java-The Complete Reference”, Seventh Edition, Tata McGraw Hill Publication
2. E. Balguruswamy, “Programming with java A primer”, Fifth edition, Tata McGraw Hill
Publication
Reference Books:
1. D.T. Editorial Services, “Java 8 Programming Black Book”, Dreamtech Press
2. H. M.Deitel, P. J. Deitel, S. E. Santry, “Advanced Java 2 Platform How to Program” Prentice Hall
3. Learn to Master JAVA, from Star EDU solutions , by ScriptDemics
Term Work:
The term Work shall consist of at least 12 to 15 practical’s based on the above list. The
also Term work Journal must include at least 2 assignments.
Term Work Marks: 50 Marks (Total marks) = 40 Marks (Experiment) + 5 Marks
(Assignments) + 5 Marks (Attendance)

Oral & Practical Exam: An Oral & Practical exam will be held based on the above syllabus

2. Course Outcome Statement

Sr.No. Course Outcome Statement


ITL304.1 Implement Object Oriented programming concept using basic syntaxes of control
Structures, Strings and function for developing skills of logic building activity.
ITL304.2 Identify classes, objects, members of a class and the relationships among them
needed for a finding the solution to specific Problem
ITL304.3 Demonstrates how to achieve reusability using inheritance, interfaces and
packages and describes faster application development can be achieved
ITL304.4 Demonstrate understanding and use of different exception handling mechanisms
and concept of multithreading for robust faster and efficient application
development.
ITL304.5 Identify and describe common abstract user interface components to design GUI
in Java using Applet & AWT along with response to events
ITL304.6 Identify, Design & develop complex Graphical user interfaces using principal
Java Swing classes based on MVC architecture
3.CO-PO and CO-PSO Mapping

Course
Name PO1 PO2 PO3 PO4 PO5 PO6 PO7 PO8 PO9 PO10 PO11 PO12 PSO1 PSO2
ITL304.1 2 1 1 1

ITL304.2 2 2 2 1 1 1

ITL304.3 2 2 2 1 1 1

ITL304.4 2 2 2 1 1 1

ITL304.5 2 2 2 1 1 1

ITL304.6 2 2 2 1 1 1

4.CO Assessment Tools

CO number Direct Measures Indirect Measures

Assign1 Assign2 Lab Univ. Course Exit Survey


Practical

ITL304.1 P1-P6(70%) 30% 100%


ITL304.2 P7-P8 (70%) 30% 100%
ITL304.3 A1 P9-P10 (40%) 30% 100%
(30%)
ITL304.4 A2 P11- 30% 100%
(30%) P12(40%)
ITL304.5 P13-P14 30% 100%
(70%)
ITL304.6 P15 (70%) 30% 100%
5. Course Outcomes Target:
Upon Completion of this course, students will be able to :

ITC502.1: Implement Object Oriented programming concept using basic syntaxes of control Structures,
Strings and function for developing skills of logic building activity. [B2:Application]
Target level: 2.0
ITC502.2: Identify classes, objects, members of a class and the relationships among them needed for a
finding the solution to specific Problem [B3:Application]
Target level: 2.0
ITC502.3 Demonstrates how to achieve reusability using inheritance, interfaces and packages and
describes faster application development can be achieved [B3:Application]
Target level: 2.0
ITC502.4: Demonstrate understanding and use of different exception handling mechanisms and concept
of multithreading for robust faster and efficient application development. [B3:Application]
Target level: 2.0
ITC502.5: Identify and describe common abstract user interface components to design GUI in Java
using Applet & AWT along with response to events [B1:Knowledge]
Target level: 2.0
ITC502.6: Identify, Design & develop complex Graphical user interfaces using principal Java Swing
classes based on MVC architecture [B3:Application]
Target level: 2.0
2. Course Outcome Statement

Sr.No. Course Outcome Statement


ITC502.1 Implement interactive web page(s) using HTML,CSS and JavaScript.

ITC502.2 Design a responsive web site using HTML5 and CSS3.

ITC502.3 Demonstrate Rich Internet Application .

ITC502.4 Build Dynamic web site using server side PHP Programming and Database connectivity.

ITC502.5 Describe and differentiate different Web Extensions and Web Services.

ITC502.6 Demonstrate web application using Python web Framework-Django

3.CO-PO and CO-PSO Mapping

Course
Name PO1 PO2 PO3 PO4 PO5 PO6 PO7 PO8 PO9 PO10 PO11 PO12 PSO1 PSO2
ITC502.1 2 3 2 3

ITC502.2 2 3 2 3
ITC502.3 2 3 2 3
ITC502.4 2 3 2 3
ITC502.5 2 3 2 3
ITC502.6 2 3 2 3

4. CO Assessment Tools

CO number Direct Measurement Indirect Measurement

UT1 UT2 Quiz Univ. Course Exit Survey


Theory

ITC502.1 40% 30% 30% 100%


ITC502.2 70% 30% 100%
ITC502.3 70% 30% 100%
ITC502.4 70% 30% 100%
ITC502.5 70% 30% 100%
ITC502.6 70% 30% 100%
5. Course Outcomes Target:
Upon Completion of this course, students will be able to :
ITL304.1: Implement interactive web page(s) using HTML,CSS and JavaScript..[B2:Application]
Target level: 2.0
ITL304.2: Design a responsive web site using HTML5 and CSS3 [B3:Application]
Target level: 2.0
ITL304.3:. Demonstrate Rich Internet Application [B3:Application]
Target level: 2.0
ITL304.4: Build Dynamic web site using server side PHP Programming and Database connectivity. [B3:Application]
Target level: 2.0
ITL304.5: Describe and differentiate different Web Extensions and Web Services. [B1:Knowledge]
Target level: 2.0
ITL304.6: Build Demonstrate web application using Python web Framework-Django [B3:Application]
Target level: 2.0

6. Lesson Plan

No of classes 20 1. No of Classes 20
available: taken:
2.Total Remedial 02
Lectures

Sr. No. Topic Planned with CO Planned Date Actual Date Delivery
Mechanisms
Don’t forget to include CO dissemination
1. Fundamental of Java 31-07-2018 31-07-2018 ppt, blackboard
Programming(ITL304.1,ITL304.2)
2. Classes, objects, arrays and 24-08-2018 24-08-2018 ppt, blackboard
recursion(ITL304.1,ITL304.2)
3. Inheritance, interface and packages(ITL304.3) 01-09-2018 01-09-2018 ppt, blackboard
4. Exception handling and Multithreading 07-09-2018 07-09-2018 ppt, blackboard
(ITL304.4)
5. Applet Programming, GUI development using 21-09-2018 21-09-2018 ppt, blackboard
AWT and event handling(ITL304.5)
6. Java Swings (ITL304.6) 28-09-2018 28-09-2018 ppt, blackboard

Date wise lecture plan

Date Topic Taught Date Topic Taught


16-07-2018 Overview of object oriented 17-07-2018 Features of Java
programming, Java design goals
24-07-2018 Keywords, data types, variables, 26-07-2018 Control structures
operators, expressions
30-07-2018 Control structures 31-07-2018 Basic programs using control
structures
04-08-2018 Class fundamentals, assigning 06-08-2018 Passing parameters to methods and
object reference variables returning parameters from
methods
10-08-2018 Nested and inner classes, 20-08-2018 Method overloading, recursion,
constructors command line arguments
24-08-2018 Wrapper classes, Arrays and 27-08-2018 Inheritance
vectors
31-02-2018 Interfaces 01-09-2018 Packages
01-09-2018 Exception handling 07-09-2018 Multithreading
10-09-2018 Applet 21-09-2018 Event driven programming
24-09-2018 Java Swing 28-09-2018 Java Swing

7.Assignment Plan

Assignment No. Date Topics with CO


1 01-10-2018 Inheritance(ITL304.3)
2 02-10-2018 Exception Handling(ITL304.4)

You might also like