Skip to content

Sanjaykannavedhachalam/STS-Enhancing-Programming-Ability-JAVA-Codes

Repository files navigation

STS Enhancing Programming Ability - Java Codes

A collection of advanced Java programming solutions focusing on data structures and algorithms.

📋 Contents

Data Structure Implementations

  • BitonicDoublyLL.java - Bitonic sequence operations in doubly linked lists
  • MergeSortDLL.java - Merge sort implementation for doubly linked lists
  • PriorityQueueDLL.java - Priority queue using doubly linked list
  • SegregateEvenOddNodes.java - Segregate even and odd nodes in linked lists
  • LoopDetection.java - Detect and remove loops in linked lists

Stack & Queue Problems

  • MinimumStack.java - Stack implementation with O(1) minimum element retrieval
  • StackPermutation.java - Validate stack permutation sequences
  • StockSpan.java - Stock span problem using stack
  • MaxSlidingWindow.java - Maximum sliding window problem

Algorithm Implementations

  • CelebrityProblem.java - Find celebrity in a group using stack
  • IterativeTowerOfHanoi.java - Iterative solution to Tower of Hanoi
  • SortWithoutExtraSpace.java - In-place sorting algorithms

🚀 Getting Started

Prerequisites

  • Java Development Kit (JDK) 8 or higher
  • Any Java IDE (Eclipse, IntelliJ IDEA, VS Code) or command line

Running the Programs

# Compile a Java file
javac FileName.java

# Run the compiled program
java FileName

📋 CAT-2 Programs

Advanced data structures and algorithms implementations for CAT-2 examination:

Tree Algorithms

  • RecoverBST.java - Recover Binary Search Tree with two swapped nodes
  • TreeViews.java - Top, Bottom, Left, and Right views of binary tree
  • VerticalOrderTraversal.java - Vertical order traversal of binary tree
  • BoundaryTraversal.java - Anti-clockwise boundary traversal of binary tree

Graph Algorithms

  • BFS_DFS.java - Breadth-First Search and Depth-First Search (Recursive & Iterative)
  • DialsAlgorithm.java - Shortest path for small integer weighted graphs
  • BellmanFord.java - Shortest path with negative weights and cycle detection
  • TopologicalSort.java - DFS and BFS (Kahn's Algorithm) based topological sorting

Heap Structures

  • HeapSort.java - In-place heap sort implementation
  • BinomialHeap.java - Binomial heap with efficient union operation
  • KaryHeap.java - K-ary heap generalization (k children per node)
  • WinnerTree.java - Tournament tree for external sorting and top-k elements

📝 Topics Covered

  • Doubly Linked Lists
  • Stack Operations
  • Queue Operations
  • Sorting Algorithms
  • Binary Search Trees
  • Tree Traversals & Views
  • Graph Traversal (BFS, DFS)
  • Shortest Path Algorithms
  • Topological Sorting
  • Advanced Heap Structures
  • Recursive & Iterative Approaches
  • Time & Space Complexity Optimization

👤 Author

Sanjay Kanna V

📄 License

This project is open source and available for educational purposes.


Part of STS Enhancing Programming Ability course

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages