{"id":19151942,"url":"https://github.com/wzslr321/algorithms_and_data_structures","last_synced_at":"2025-05-07T05:43:11.740Z","repository":{"id":129167674,"uuid":"401735492","full_name":"wzslr321/algorithms_and_data_structures","owner":"wzslr321","description":"C++ code which I will wrote during my hopefully fruitful relationship with competetive programming","archived":false,"fork":false,"pushed_at":"2024-03-10T19:14:13.000Z","size":3791,"stargazers_count":3,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-03-10T20:28:56.740Z","etag":null,"topics":["algorithms","algorithms-and-data-structures","competitive-programming","cpp","data-structures"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/wzslr321.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2021-08-31T14:34:22.000Z","updated_at":"2023-12-04T21:53:54.000Z","dependencies_parsed_at":"2023-12-17T22:20:51.241Z","dependency_job_id":"7c123a88-0f6f-45f3-8c0f-171f32b50b00","html_url":"https://github.com/wzslr321/algorithms_and_data_structures","commit_stats":null,"previous_names":["wzslr321/algorithms_and_data_structures"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wzslr321%2Falgorithms_and_data_structures","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wzslr321%2Falgorithms_and_data_structures/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wzslr321%2Falgorithms_and_data_structures/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wzslr321%2Falgorithms_and_data_structures/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/wzslr321","download_url":"https://codeload.github.com/wzslr321/algorithms_and_data_structures/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":223800818,"owners_count":17205010,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["algorithms","algorithms-and-data-structures","competitive-programming","cpp","data-structures"],"created_at":"2024-11-09T08:16:06.977Z","updated_at":"2024-11-09T08:16:07.494Z","avatar_url":"https://github.com/wzslr321.png","language":"C++","readme":"## Overview\n\nThis repository contains code (mostly C++) responsible \nfor **Algorithms \u0026 Data Structures**. \u003cbr\u003e\u003cbr\u003e\n`Algorithms` implementations of popular algorithms. \u003cbr\u003e\u003cbr\u003e\n`Data Structures` directory contains implementation of data structures. \u003cbr\u003e\u003cbr\u003e\n`Problems` solutions for **Leetcode** \u0026 **Codeforces** problems. \u003cbr\u003e\u003cbr\u003e\n`Library` code for competitive programming related patterns, which is my *cheatsheet*. \u003cbr\u003e\u003cbr\u003e\n`Cpp` notes \u0026 code related to C++ itself, not any specific algorithm.\n\n---\n\n## Table of contents\n- [Algorithms](https://github.com/wzslr321/algorithms_and_data_structures/tree/main#algorithms)\n- [Data Structures](https://github.com/wzslr321/algorithms_and_data_structures/tree/main#data-structures)\n- [Problems](https://github.com/wzslr321/algorithms_and_data_structures/tree/main#problems)\n  - [Leetcode Medium](https://github.com/wzslr321/algorithms_and_data_structures/tree/main#leetcode-medium)\n  - [Leetcode Hard](https://github.com/wzslr321/algorithms_and_data_structures/tree/main#leetcode-hard)\n  - [Codeforces](https://github.com/wzslr321/algorithms_and_data_structures/tree/main#codeforces) \n- [Library](https://github.com/wzslr321/algorithms_and_data_structures/tree/main#library)\n- [Cpp](https://github.com/wzslr321/algorithms_and_data_structures/tree/main#cpp)\n\n\n---\n\n### Algorithms\n- [Bellman-Ford](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/algorithms/bellman_ford)\n- [Dijkstra](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/algorithms/dijkstra)\n- [Knapsack](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/algorithms/knapsack)\n- [Topological Sort](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/algorithms/topological_sort)\n\n---\n\n### Data Structures\n- [Doubly Linked List](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/data_structures/doubly_linked_list)\n- [Binary Tree](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/data_structures/binary_tree)\n- [Rooted Tree](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/data_structures/better_rooted_tree)\n- [Fenwick Tree](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/data_structures/fenwick_tree)\n- [AVL Tree](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/data_structures/avl_tree)\n- [Red-Black Tree](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/data_structures/red_black_tree)\n\n---\n\n### Problems\n\n####  Leetcode Medium \n\n- [3. Longest Substring Without Repeating Characters](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-3) \n- [6. Zigzag Conversion](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-6) \n- [7. Reverse Integer](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-7)  \n- [11. Container With Most Water](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-11) \n- [12. Integer to Roman](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-12) \n- [15. 3Sum](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-15) \n- [19. Remove Nth Node From End of List](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-19)\n- [33. Search in Rotated Sorted Array](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-33)\n- [45. Jump Game II](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-45)\n- [49. Group Anagrams](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-49)\n- [53. Maximum Subarray](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-53)\n- [55. Jump Game](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-55)\n- [56. Merge Intervals](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-56)\n- [80. Remove Duplicated from Sorted Array II](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-80)\n- [81. Search in Rotated Sorted Array II](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-81)\n- [122. Best Time to Buy and Sell Stock II](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-122)\n- [128. Longest Consecutive Sequence](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-128)\n- [134. Gas Station](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-134)\n- [148. Sort List](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-148) \n- [151. Reverse Words in a String](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-151)\n- [167. Two Sum || Input Array Is Sorted](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-167)\n- [189. Rotate Array](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-189)\n- [200. Number of Islands](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-200)\n- [209. Minimum Size Subarray Sum](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-209)\n- [238. Product of Array Except Self](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-238)\n- [274. H-Index](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-274)\n- [380. Insert Delete GetRandom O(1)](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-380)\n- [382. Linked List Random Node](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-382)\n- [451. Sort Characters By Frequency](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-451)\n- [518. Coim Change II](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-518)\n- [849. Maximize Distance to Closest Person](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-849)\n- [852. Peak Index in a Mountain Array](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-852)\n- [921. Minimum Add to Make Parentheses Valid](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-921)\n- [1282. Group the People Given the Group Size They Belong to](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-1282)\n- [1476. Subrectangle Queries](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-1476)\n- [1492. The kth Factor of n](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-1492)\n- [1525. Number of Good Ways to Split a String](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-1525)\n- [1615. Maximal Network Rank](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-1615)\n- [1689. Partitioning Into Minimum Number of Deci-Binary Numbers](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-1689)\n- [1769. Minimum Number of Operations to Move All Balls to Each Box](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-1769)\n- [1828. Queries on Number of Points Inside a Circle](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-1828)\n- [2130. Maximum Twin Sum of a Linked List](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-2130)\n- [2181. Merge Nodes in Between Zeros](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-2181)\n- [2134. Minimum Swaps to Group All 1's Together II](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-2134)\n- [2428. Maximum Sum of an Hourglass](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-2428)\n- [2616. Minimze the Maximum Difference on Pairs](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-2616)\n\n---\n\n#### Leetcode Hard\n\n- [42. Trapping Rain Water](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-42)\n- [239. Sliding Window Maximum](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/leetcode-239)\n\n---\n\n#### Codeforces\nranked \u003e= 1200, sorted descending\n\n\n- [1623C Balanced Stone Heaps { 1600 | binary search | greedy }](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/codeforces-1623c)\n- [1886C Decreasing String { 1600 | implementation | strings}](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/codeforces-1886c)\n- [1851E Nastya And Potions { 1500 | dfs and similar | dp | graphs | sortings}](https://github.com/wzslr321/algorithms_and_data_structures/blob/main/problems/codeforces-1851e/main.cpp)\n- [1898B Milena and Admirer {1500 | greedy | math} ](https://github.com/wzslr321/algorithms_and_data_structures/blob/main/problems/codeforces-1898b/main.cpp)\n- [982C Cut 'em All{ 1500 | dfs and similar | dp | graphs | greedy | trees }](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/codeforces-982c)\n- [1891C Smilo and Monsters {1500 | binary search | constructive algorithms | greedy | sortings | two pointers}](https://github.com/wzslr321/algorithms_and_data_structures/blob/main/problems/codeforces-1891c/main.cpp)\n- [165B Burning Midnight Oil { 1500 | binary search | implementation }](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/codeforces-165b/) \n- [279B Books { 1400 | binary search | brute force | implementation | two pointers }](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/codeforces-279b)\n- [1612C Chat Ban { 1300 | binary search | math}](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/codeforces-1612c)\n- [1902C Insert and Equalize {1300 | brute force | constructive algorithms | greedy | math | number theory}](https://github.com/wzslr321/algorithms_and_data_structures/blob/main/problems/codeforces-1902c/main.cpp)\n- [1900C Anji's Binary Tree {1300 | dfs and similar | dp | trees}](https://github.com/wzslr321/algorithms_and_data_structures/blob/main/problems/codeforces-1900c/main.cpp)\n- [474B Worms { 1200 | binary search | implementation }](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/codeforces-474b)\n- [1221C Perfect Team { 1200 | binary search | math}](https://github.com/wzslr321/algorithms_and_data_structures/tree/main/problems/codeforces-1221c)\n- [1886B - Fear of the Dark { 1200 | binary search | geometry | math} ](https://github.com/wzslr321/algorithms_and_data_structures/blob/main/problems/codeforces-1886b/main.cpp)\n\n---\n\n### Library\n\n- [Binary Exponentation](https://github.com/wzslr321/algorithms_and_data_structures/blob/main/library/algebra/binary_exponentation.cpp)\n- [Euclidian Algorithm](https://github.com/wzslr321/algorithms_and_data_structures/blob/main/library/algebra/euclidian_algorithm.cpp)\n- [Linear Diophantine Equations](https://github.com/wzslr321/algorithms_and_data_structures/blob/main/library/algebra/linear_diophantine_equations.cpp)\n- [Depth First Search](https://github.com/wzslr321/algorithms_and_data_structures/blob/main/library/depth_first_search.cpp)\n\n### Cpp\n\n\n\nMy profiles on algorithmic sites:\n\n- [Codeforces Profile](https://codeforces.com/profile/Creatix)\n- [Leetcode Profile](https://leetcode.com/wzslr321)\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwzslr321%2Falgorithms_and_data_structures","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwzslr321%2Falgorithms_and_data_structures","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwzslr321%2Falgorithms_and_data_structures/lists"}