{"id":24054501,"url":"https://github.com/etherbeing/exact_remaining","last_synced_at":"2026-05-16T07:46:50.737Z","repository":{"id":128645492,"uuid":"577897169","full_name":"etherbeing/exact_remaining","owner":"etherbeing","description":"Simple math formula to get a number that when substracting a percent value it returns the original number","archived":false,"fork":false,"pushed_at":"2022-12-13T20:12:22.000Z","size":6,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-09T03:46:16.651Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/etherbeing.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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,"publiccode":null,"codemeta":null}},"created_at":"2022-12-13T19:22:59.000Z","updated_at":"2022-12-13T19:32:21.000Z","dependencies_parsed_at":null,"dependency_job_id":"405238ab-eeb9-4897-ad76-d3291e65761f","html_url":"https://github.com/etherbeing/exact_remaining","commit_stats":null,"previous_names":["etherbeing/exact_remaining"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/etherbeing%2Fexact_remaining","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/etherbeing%2Fexact_remaining/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/etherbeing%2Fexact_remaining/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/etherbeing%2Fexact_remaining/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/etherbeing","download_url":"https://codeload.github.com/etherbeing/exact_remaining/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240840105,"owners_count":19866168,"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":[],"created_at":"2025-01-09T03:46:32.367Z","updated_at":"2026-05-16T07:46:45.715Z","avatar_url":"https://github.com/etherbeing.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Exact Remaining\nSimple math formula to get a number that when substracting a percent value it returns the original number\n\n# Use cases \nThe origin of this was thinking how can a seller increase a product price to a total that when substracting a percent from that total the resulting total becomes the wanted total, for example lets say we want to sell a product in 200 $ but for example PayPal will take its 2.9% from that transaction, but we need to sell the product in 200$ because if not we are going to lose money, we want to get an acurrate way of doing so, for that we use the exact remaining formula that give us a number that when substracting a percent amount will going to return us the exact number we want...\n\nwith the previous values lets write the math formula:\n\nn = (x*p)/(100-p) where n is number to be added to the total and x is the total and p is the percent someone is going to take from our total\nso replacing the previous values in the previous formula we got that\n\nn = ((200*2.9)/(100-2.9))\n\nso n = 5.973223480947477\n\nnow if we add n to x we got that\n\nt = n + x \n\nt = 205.97322348094747\n\nfinally when substracting the 2.9 percent of t minus t we got the initial x\n\nx = t - ((t*2.9)/100) this is True as left member is equal to right member\n\nwhen using a language like python for this please use round as some values may get an infinite value as the division is not always exact\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fetherbeing%2Fexact_remaining","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fetherbeing%2Fexact_remaining","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fetherbeing%2Fexact_remaining/lists"}