-
Advanced Java Features (Object-Oriented Programming, Generics, Collections Framework)
- #1: Implement a Design Pattern
- #2: Leverage Inner Classes for Data Encapsulation
- #3: Create a Generic Method for Data Validation
- #4: Design a Generic Class for Stack Data Structure
- #5: Implement a Thread-Safe Cache using ConcurrentHashMap
- #6: Process a Collection using Stream API and Custom Comparator
-
Advanced Algorithms: Greedy Algorithms and Dynamic Programming
- Choose a design pattern like Factory Method or Strategy.
- Design a real-world scenario applicable to the chosen pattern and implement it in Java using classes and methods.
- ./IL-Week-1/README.md
- Create a class with an inner class to encapsulate helper functionality or data related to the outer class.
- ./IL-Week-1/README.md
- Implement a generic method that can validate different data types (e.g., numbers, strings) based on specific criteria.
- ./IL-Week-1/README.md
- Create a generic Stack class that can hold objects of any data type, utilizing generics for type safety.
- ./IL-Week-1/README.md
- Design a simple in-memory cache using ConcurrentHashMap to store key-value pairs with thread safety considerations.
- ./IL-Week-1/README.md
- Choose a collection of data (e.g., list of objects).
- Implement a custom comparator to sort the collection based on specific criteria.
- Utilize the Stream API to filter, transform, and process elements within the sorted collection.
- ./IL-Week-1/README.md
- Create methods that throw both checked and unchecked exceptions.
- Implement try-catch blocks to handle these exceptions appropriately, demonstrating the difference in handling requirements.
- ./IL-Week-1/README.md
- Simulate a scenario where you might need to handle multiple exceptions within nested code blocks.
- Implement nested try-catch blocks to catch specific exceptions at different levels of your code.
- ./IL-Week-1/README.md
- Create a method that opens a file for reading.
- Use a try-catch block to handle potential IOException while reading the file.
- Ensure the file is closed using a finally block, regardless of exceptions.
- ./IL-Week-1/README.md
- Design a scenario where a custom exception would be beneficial for your application.
- Create a custom exception class extending an appropriate base class (e.g.,
RuntimeException
). - Throw your custom exception within your code and handle it using a try-catch block.
- ./IL-Week-1/README.md
- Simulate processing multiple images concurrently using a thread pool.
- Utilize an ExecutorService and create separate tasks for processing each image.
- ./IL-Week-1/README.md
- Create a class with a shared counter variable and a method to increment it.
- Implement a synchronized block to ensure thread safety when updating the counter variable.
- ./IL-Week-1/README.md
- Simulate a deadlock scenario involving two threads and two resources.
- Analyze the deadlock and modify your code to avoid it using proper lock ordering.
- ./IL-Week-1/README.md
- Design and implement an AVL Tree class with methods for insertion, deletion, and searching.
- Explore balancing operations (rotations) to maintain AVL Tree properties for efficient search and insertion.
- ./IL-Week-1/README.md
- Simulate a task scheduling scenario where tasks have priorities.
- Implement a Min Heap (priority queue) to efficiently schedule tasks based on their priority.
- ./IL-Week-1/README.md
- Design a Trie data structure to store a set of words.
- Implement methods to search for prefixes and retrieve words that start with a given prefix.
- ./IL-Week-1/README.md
- Represent a graph using an adjacency list or adjacency matrix.
- Implement a DFS algorithm to traverse all nodes in the graph, exploring connected nodes recursively.
- ./IL-Week-1/README.md
- Design a scenario with a weighted graph representing a road network.
- Implement Dijkstra's algorithm to find the shortest path between two nodes in the graph based on edge weights (distances).
- ./IL-Week-1/README.md
- Create a weighted graph representing connections between cities.
- Implement Prim's algorithm to find the minimum spanning tree that connects all cities with minimal total connection cost.
- ./IL-Week-1/README.md
- Design a solution for the fractional knapsack problem, where you can take portions of items.
- Implement a greedy algorithm that prioritizes items with the highest value-to-weight ratio to
- fill the knapsack as much as possible while staying within the weight limit.
- ./IL-Week-1/README.md
- Create a dynamic programming solution for finding the LCS of two given strings.
- Utilize a table to store solutions to subproblems (overlapping subsequences) and efficiently construct the LCS string.
- ./IL-Week-1/README.md