Skip to content

Shyam5806/Project-5

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

5 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Project-5

πŸ“˜ Week 5 Java Mini Projects – Linked List Applications Welcome to the Week 5 Java Mini Projects Repository! This week focused on applying core Linked List concepts through problem-solving and algorithm implementation. Below are the three mini-projects built with detailed descriptions.

πŸ”Ή 1. Palindrome Linked List Checker πŸ“„ Description This program checks whether a given singly linked list is a palindrome or not. It uses the fast and slow pointer approach to find the middle of the list and then reverses the second half to compare both halves.

🧠 Concepts Used Fast and slow pointer technique

Linked list reversal

Comparison of node values

βœ… Sample Output Is Palindrome: true

πŸ”Ή 2. Find N-th Node From the End πŸ“„ Description A common interview question where the goal is to find the N-th node from the end of a singly linked list using a two-pointer approach.

🧠 Concepts Used Two-pointer technique

Edge case handling

Efficient single-pass traversal

βœ… Sample Output 2nd node from end: 40

πŸ”Ή 3. Floyd's Cycle Detection (Hare-Tortoise Algorithm) πŸ“„ Description This project implements Floyd's Cycle Detection Algorithm, also known as the Hare and Tortoise method, to detect a cycle (loop) in a linked list.

🧠 Concepts Used Cycle detection using fast and slow pointers

Detecting repeated nodes in O(n) time and O(1) space

βœ… Sample Output Cycle detected: true

πŸ“ Project Structure Copy Edit Week5_Java_Projects/ β”œβ”€β”€ PalindromeLinkedList.java β”œβ”€β”€ FindNthFromEnd.java β”œβ”€β”€ DetectCycle.java └── README.md πŸ“Œ Key Learning Outcomes Strong understanding of pointer manipulation in Linked Lists

Applied time and space-efficient techniques

Practiced and implemented real-world DSA interview problems

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors