Skip to content

Latest commit

 

History

3 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

☕ Java Practicals — Semester 4

Data Structures & Algorithms • Object-Oriented Programming • Advanced Java Problem Solving



A structured collection of Java programs, Data Structures & Algorithms implementations, Object-Oriented Programming exercises, and problem-solving implementations completed during Semester 4.


Focused on advanced data structures, algorithmic techniques, graph and tree algorithms, dynamic programming, hashing, sorting, multithreading, and competitive programming problems.

📌 About This Repository

This repository contains my Java practical programs and Data Structures & Algorithms implementations from Semester 4. It serves as a centralized collection of programs developed during academic practical sessions, assignments, algorithmic exercises, and programming practice.

The repository builds upon fundamental Java programming concepts and focuses on solving more complex computational problems using appropriate data structures and algorithms.

The practical implementations cover topics including arrays, linked lists, stacks, queues, trees, graphs, hashing, sorting, divide and conquer, dynamic programming, multithreading, and Object-Oriented Programming.


🎯 Objectives

  • Strengthen Java programming and problem-solving skills
  • Understand and implement advanced data structures
  • Analyze and apply different algorithmic techniques
  • Improve time and space complexity awareness
  • Implement graph traversal and shortest-path algorithms
  • Work with trees and hierarchical data structures
  • Apply hashing techniques to programming problems
  • Understand divide-and-conquer algorithms
  • Explore dynamic programming approaches
  • Practice sorting and searching algorithms
  • Understand stacks and queues through practical problems
  • Implement multithreading concepts in Java
  • Apply Object-Oriented Programming principles
  • Develop solutions to LeetCode-style programming problems

🛠️ Technologies & Tools




📚 Concepts Covered

The repository covers a broad range of Data Structures, Algorithms, Java programming concepts, and practical problem-solving techniques.

Category Concepts / Implementations
Arrays Array manipulation, searching, rotation and problem solving
Linked Lists Nodes, linked list operations, merging and list-based problems
Stacks & Queues Stack operations, queue operations and practical applications
Trees Tree structures, traversal and tree-based problem solving
Graphs Graph representation, traversal and shortest-path algorithms
Dijkstra's Algorithm Shortest-path computation in weighted graphs
Hashing HashMap and hash-based problem solving
Sorting Sorting algorithms and comparative problem solving
Divide & Conquer Recursive problem decomposition and divide-and-conquer techniques
Dynamic Programming Optimization problems using dynamic programming techniques
OOP Classes, objects, inheritance and Object-Oriented Programming
Multithreading Threads and concurrent execution in Java
Problem Solving LeetCode-style problems, validation, optimization and algorithm design

🧩 Data Structures

🔢 Arrays

Array-based programs demonstrate techniques for manipulating, searching, rotating, and processing collections of elements.

🔗 Linked Lists

Linked list implementations demonstrate nodes, connections between nodes, traversal, and common list-based operations.

📚 Stacks & Queues

Stack and queue implementations demonstrate fundamental linear data structures and their applications in algorithmic problems.

🌳 Trees

Tree-based programs introduce hierarchical data structures and tree traversal and problem-solving techniques.

🕸️ Graphs

Graph-based implementations demonstrate algorithms for working with relationships and paths between interconnected nodes.


🧠 Algorithms

📍 Dijkstra's Algorithm

The repository includes an implementation of Dijkstra's shortest-path algorithm for finding minimum-cost paths in weighted graphs.

🔀 Sorting

Sorting implementations provide practical experience with arranging data and understanding algorithmic efficiency.

🔄 Divide & Conquer

Divide-and-conquer implementations demonstrate how complex problems can be recursively divided into smaller subproblems and combined to produce a final solution.

🧮 Dynamic Programming

Dynamic programming implementations focus on solving optimization problems by breaking them into overlapping subproblems and reusing previously computed results.


💻 LeetCode Problem Solving

The repository contains several LeetCode-oriented folders and implementations used to practice algorithmic problem solving.

These include problems involving:

  • Arrays
  • Linked Lists
  • Palindromes
  • Stacks and Queues
  • Trees
  • Hashing
  • String validation
  • Anagram validation
  • Array rotation
  • Time complexity and optimization

These exercises help strengthen the ability to translate problem statements into efficient Java implementations.


⚡ Algorithmic Techniques

The practical implementations explore different approaches to solving computational problems efficiently.

Problem
   ↓
Understand Constraints
   ↓
Select Data Structure
   ↓
Choose Algorithm
   ↓
Implement in Java
   ↓
Test Edge Cases
   ↓
Analyze Time Complexity
   ↓
Analyze Space Complexity
   ↓
Optimize Solution

🧵 Multithreading

The repository also includes practical implementations related to Java threads and concurrent execution.

Multithreading exercises provide an introduction to executing multiple tasks concurrently and understanding the fundamentals of Java's threading model.

Topics include:

  • Thread creation
  • Thread execution
  • Concurrent tasks
  • Thread lifecycle
  • Basic multithreading concepts

🧱 Object-Oriented Programming

The repository contains dedicated practical work related to Object-Oriented Programming and Java class design.

Classes & Objects

Programs demonstrate the creation of classes and objects to model data and functionality.

Inheritance

Inheritance-based implementations demonstrate relationships between classes and code reuse through parent-child class structures.

Encapsulation

Object-oriented implementations demonstrate the organization and protection of data within classes.


⏱️ Complexity & Optimization

An important focus of the repository is understanding the efficiency of different algorithms.

Solutions are considered not only for correctness but also in terms of their computational requirements.

Complexity Purpose
O(1) Constant-time operations
O(log n) Logarithmic algorithms
O(n) Linear-time algorithms
O(n log n) Efficient sorting and divide-and-conquer approaches
O(n²) Nested iteration and quadratic solutions

▶️ Getting Started

Prerequisites

  • Java JDK 8 or later
  • Java-compatible IDE or code editor
  • Basic understanding of Java programming

Clone the Repository

git clone https://github.com/KuunalMistry/Java-Practicals-Sem-4.git

Navigate to the Repository

cd Java-Practicals-Sem-4

Compile a Java Program

javac ProgramName.java

Run the Program

java ProgramName

Individual programs can also be opened and executed using IntelliJ IDEA, VS Code, Eclipse, or another Java-compatible IDE.


🧑‍💻 Development Environment


📸 Practical Outputs

Program outputs and screenshots can be added to individual practical folders to document successful execution and demonstrate the results of each implementation.

For algorithmic problems, sample inputs, outputs, and complexity analysis can also be documented alongside the source code.


📝 Learning Outcomes

Through these practical implementations, the following skills are developed:

  • Advanced Java programming and problem solving
  • Understanding and implementing fundamental data structures
  • Applying appropriate algorithms to computational problems
  • Working with arrays, linked lists, stacks and queues
  • Understanding trees and graphs
  • Implementing shortest-path algorithms
  • Using HashMap for efficient data access
  • Applying sorting and searching techniques
  • Understanding divide-and-conquer strategies
  • Applying dynamic programming techniques
  • Understanding Object-Oriented Programming
  • Working with Java threads
  • Analyzing time and space complexity
  • Solving LeetCode-style programming problems

🔍 Code Quality Practices

  • Use meaningful variable, class, and method names
  • Maintain readable and properly formatted Java code
  • Select appropriate data structures for each problem
  • Consider time and space complexity
  • Handle edge cases wherever required
  • Avoid unnecessary code duplication
  • Keep individual implementations focused
  • Use comments where algorithmic logic requires clarification
  • Maintain a clean and organized repository

📌 Practical Checklist

Concept / Area Status
Arrays ⬜
Linked Lists ⬜
Stacks & Queues ⬜
HashMap / Hashing ⬜
Trees ⬜
Graphs ⬜
Dijkstra's Algorithm ⬜
Sorting ⬜
Divide & Conquer ⬜
Dynamic Programming ⬜
Object-Oriented Programming ⬜
Inheritance ⬜
Multithreading ⬜
LeetCode Problem Solving ⬜

📚 Purpose of This Repository

This repository serves as an academic record of my Java practical programs, Data Structures & Algorithms implementations, and problem-solving exercises completed during Semester 4.

It also acts as a reference for revisiting data structures, algorithmic techniques, Object-Oriented Programming concepts, and Java implementations developed throughout the semester.

The programs are intended primarily for educational and academic purposes.


👨‍💻 Author

Kuunal Mistry


B.Tech Student | Artificial Intelligence & Machine Learning




About

leetcodes/theory

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages