{"id":27312976,"url":"https://github.com/zainabdnaya/push_swap_42","last_synced_at":"2025-04-12T06:50:04.516Z","repository":{"id":197607252,"uuid":"353996332","full_name":"zainabdnaya/Push_Swap_42","owner":"zainabdnaya","description":"sort data on a stack, with a limited set of instructions, using the lowest possible number of actions","archived":false,"fork":false,"pushed_at":"2022-03-17T08:41:07.000Z","size":3196,"stargazers_count":11,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-12T06:49:56.634Z","etag":null,"topics":["42","sort","sort-data","stacks","swap"],"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/zainabdnaya.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}},"created_at":"2021-04-02T11:17:14.000Z","updated_at":"2024-05-27T09:28:11.000Z","dependencies_parsed_at":"2023-10-01T18:19:18.032Z","dependency_job_id":null,"html_url":"https://github.com/zainabdnaya/Push_Swap_42","commit_stats":null,"previous_names":["zainabdnaya/push_swap_42"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zainabdnaya%2FPush_Swap_42","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zainabdnaya%2FPush_Swap_42/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zainabdnaya%2FPush_Swap_42/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zainabdnaya%2FPush_Swap_42/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/zainabdnaya","download_url":"https://codeload.github.com/zainabdnaya/Push_Swap_42/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248530605,"owners_count":21119595,"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":["42","sort","sort-data","stacks","swap"],"created_at":"2025-04-12T06:50:03.960Z","updated_at":"2025-04-12T06:50:04.502Z","avatar_url":"https://github.com/zainabdnaya.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# push_swap\nsort data on a stack, with a limited set of instructions, using the lowest possible number of actions\n\n## Explanation about The algorithm that I use :\n  \u003ca href=\"https://diyanazizo13.medium.com/fastest-push-swap-algorithm-2f510028602b\"\u003ealgorithm push_swap \u003c/a\u003e \n## To Test\n Try to use : ./push_swap -h \"this command will show what to do \" \n## Concept of this Project ##\n\n The idea is simple, You have two stacks called Stack A and Stack B. \u003cbr\u003e\n Stack A is given a random list of unorganized numbers.  \u003cbr\u003e\n You must take the random list of numbers in Stack A and sort them so that Stack A is organized from smallest to largest. \u003cbr\u003e \n There are only a few moves you’re allowed to used to manipulate the stacks that we’re going to call “Actions”.  \u003cbr\u003e\n The main goal of this project is to organize Stack A in as few actions as possible. \u003cbr\u003e\n\n ## MOVES ##\n\nthe moves are named:  sa, sb, ss, ra, rb, rr, rra, rrb, rrr, pa, pb.\u003cbr\u003e\nI use Double linked list to implement these moves :\u003cbr\u003e\n\n## sa || sb :arrows_clockwise:  ##\n    -swap 2 first element\n\u003ca href=\"https://ibb.co/wC6FY2V\"\u003e\u003cimg src=\"https://i.ibb.co/828LXQq/Screen-Shot-2021-04-03-at-12-44-32-PM.png\" alt=\"Screen-Shot-2021-04-03-at-12-44-32-PM\" border=\"0\"\u003e\u003c/a\u003e\n##  :arrow_heading_up: ra || rb :arrow_right_hook:\t ##\n    -put the first element last,and all elemnt go UP by one \n\u003ca href=\"https://ibb.co/9ggTtbY\"\u003e\u003cimg src=\"https://i.ibb.co/YQQkZcj/Screen-Shot-2021-04-03-at-2-51-42-PM.png\" alt=\"Screen-Shot-2021-04-03-at-2-51-42-PM\" border=\"0\"\u003e\u003c/a\u003e\n\n##  :arrow_heading_down: rra || rrb :arrows_counterclockwise: ##\n    -put the last element First, so all elements go DOWN by ine element \n\u003ca href=\"https://ibb.co/k6NrLj8\"\u003e\u003cimg src=\"https://i.ibb.co/KzTQtdq/Screen-Shot-2021-04-03-at-5-26-13-PM.png\" alt=\"Screen-Shot-2021-04-03-at-5-26-13-PM\" border=\"0\"\u003e\u003c/a\u003e\n\n## pa || pb :arrow_right: ##\n    -take the first element at the top of a stack and put it at the top of other_stack.\n\u003ca href=\"https://ibb.co/Byf5G3C\"\u003e\u003cimg src=\"https://i.ibb.co/qND3Cjr/Screen-Shot-2021-04-03-at-6-41-55-PM.png\" alt=\"Screen-Shot-2021-04-03-at-6-41-55-PM\" border=\"0\"\u003e\u003c/a\u003e\n\u003ca href=\"https://ibb.co/j4Kjp2F\"\u003e\u003cimg src=\"https://i.ibb.co/kcnPdfF/Screen-Shot-2021-04-04-at-3-27-57-PM.png\" alt=\"Screen-Shot-2021-04-04-at-3-27-57-PM\" border=\"0\"\u003e\u003c/a\u003e\n\n## Checker:\n    -Thanks to the checker program, you will be able to check if the\n    list of instructions you’ll generate with the program push_swap is\n    actually sorting the stack properly.\n\n## This is how much instructions the algorithm Do with 100 random number \n\u003ca href=\"https://ibb.co/TTbfy6W\"\u003e\u003cimg src=\"https://i.ibb.co/j5WNtmJ/Screen-Shot-2021-04-11-at-2-46-15-PM.png\" alt=\"Screen-Shot-2021-04-11-at-2-46-15-PM\" border=\"0\"\u003e\u003c/a\u003e\n\n\u003ca href=\"https://ibb.co/Rb0SvY5\"\u003e\u003cimg src=\"https://i.ibb.co/jfM56bp/Screen-Shot-2021-04-11-at-2-33-56-PM.png\" alt=\"Screen-Shot-2021-04-11-at-2-33-56-PM\" border=\"0\"\u003e\u003c/a\u003e\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzainabdnaya%2Fpush_swap_42","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzainabdnaya%2Fpush_swap_42","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzainabdnaya%2Fpush_swap_42/lists"}