From 2801bd740cd35f8f8433d7cb925faf157fd07306 Mon Sep 17 00:00:00 2001 From: Gummalla Jashnavi <2400032492@kluniversity.in> Date: Fri, 7 Nov 2025 19:12:58 +0530 Subject: [PATCH 1/5] Added Java solution - Remove Zeros from Number --- removeZeros.java | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 removeZeros.java diff --git a/removeZeros.java b/removeZeros.java new file mode 100644 index 00000000..14382596 --- /dev/null +++ b/removeZeros.java @@ -0,0 +1,30 @@ +/* +LeetCode Problem: Remove Zeros from a Number +-------------------------------------------- +Description: +Given a number n, remove all the zeros from it and return the resulting number. + +Example: +Input: n = 102030 +Output: 123 + +Approach: +Convert the number to a string, remove all '0' characters using String.replace(), +and parse the result back to a long. + +Time Complexity: O(d), where d is the number of digits. +Space Complexity: O(d) +*/ + +class Solution { + public long removeZeros(long n) { + String str = String.valueOf(n); + String res = str.replace("0", ""); + return Long.parseLong(res); + } + + public static void main(String[] args) { + Solution s = new Solution(); + System.out.println(s.removeZeros(102030)); // Output: 123 + } +} From 76b5ec632cf123faa45c36a2728f043c5adc96e6 Mon Sep 17 00:00:00 2001 From: Gummalla Jashnavi <2400032492@kluniversity.in> Date: Wed, 12 Nov 2025 22:00:27 +0530 Subject: [PATCH 2/5] docs: add Hacktoberfest documentation contribution guide --- docs/Hacktoberfest_Guide.md | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 docs/Hacktoberfest_Guide.md diff --git a/docs/Hacktoberfest_Guide.md b/docs/Hacktoberfest_Guide.md new file mode 100644 index 00000000..39caabb6 --- /dev/null +++ b/docs/Hacktoberfest_Guide.md @@ -0,0 +1,19 @@ +# Hacktoberfest Documentation Contribution Guide + +👋 Welcome contributors! +This repository focuses on **documentation-only** contributions. + +## ✅ What You Can Contribute +- Fix typos or grammar in README files +- Add short explanations to existing documentation +- Improve formatting (headings, code blocks, etc.) +- Add contribution tips for beginners + +## 🚀 How to Contribute +1. Fork this repository +2. Create a new branch: `docs/update-readme` +3. Make your changes +4. Open a Pull Request with the title: + **"docs: improve documentation clarity"** + +Thank you for contributing to open-source documentation! From 384718fc3c6e20379b2efa1826240a69b6fd389c Mon Sep 17 00:00:00 2001 From: Gummalla Jashnavi <2400032492@kluniversity.in> Date: Thu, 13 Nov 2025 22:16:36 +0530 Subject: [PATCH 3/5] chore: remove non-doc file accidentally committed --- removeZeros.java | 30 ------------------------------ 1 file changed, 30 deletions(-) delete mode 100644 removeZeros.java diff --git a/removeZeros.java b/removeZeros.java deleted file mode 100644 index 14382596..00000000 --- a/removeZeros.java +++ /dev/null @@ -1,30 +0,0 @@ -/* -LeetCode Problem: Remove Zeros from a Number --------------------------------------------- -Description: -Given a number n, remove all the zeros from it and return the resulting number. - -Example: -Input: n = 102030 -Output: 123 - -Approach: -Convert the number to a string, remove all '0' characters using String.replace(), -and parse the result back to a long. - -Time Complexity: O(d), where d is the number of digits. -Space Complexity: O(d) -*/ - -class Solution { - public long removeZeros(long n) { - String str = String.valueOf(n); - String res = str.replace("0", ""); - return Long.parseLong(res); - } - - public static void main(String[] args) { - Solution s = new Solution(); - System.out.println(s.removeZeros(102030)); // Output: 123 - } -} From 6dac1c896909902ca6942ef55e61e56f7f74c089 Mon Sep 17 00:00:00 2001 From: Gummalla Jashnavi <2400032492@kluniversity.in> Date: Thu, 13 Nov 2025 22:40:01 +0530 Subject: [PATCH 4/5] Delete docs directory --- docs/Hacktoberfest_Guide.md | 19 ------------------- 1 file changed, 19 deletions(-) delete mode 100644 docs/Hacktoberfest_Guide.md diff --git a/docs/Hacktoberfest_Guide.md b/docs/Hacktoberfest_Guide.md deleted file mode 100644 index 39caabb6..00000000 --- a/docs/Hacktoberfest_Guide.md +++ /dev/null @@ -1,19 +0,0 @@ -# Hacktoberfest Documentation Contribution Guide - -👋 Welcome contributors! -This repository focuses on **documentation-only** contributions. - -## ✅ What You Can Contribute -- Fix typos or grammar in README files -- Add short explanations to existing documentation -- Improve formatting (headings, code blocks, etc.) -- Add contribution tips for beginners - -## 🚀 How to Contribute -1. Fork this repository -2. Create a new branch: `docs/update-readme` -3. Make your changes -4. Open a Pull Request with the title: - **"docs: improve documentation clarity"** - -Thank you for contributing to open-source documentation! From 1eec84920c00dcb4e05af311ed97b06caa1e2e16 Mon Sep 17 00:00:00 2001 From: Gummalla Jashnavi <2400032492@kluniversity.in> Date: Thu, 13 Nov 2025 22:45:03 +0530 Subject: [PATCH 5/5] docs: fix minor grammar and clarity issues in CONTRIBUTING.md --- CONTRIBUTING.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index ad8aec88..b1145141 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,12 +1,12 @@ # Contributing to this repo -This is a host repo to another repos, so there isn't much to contribute to it. +This is a host repository for other repositories, so there isn't much to contribute to it. But if you do have something to contribute, the only requirements are: - The contribution should not be "spammy" -- No edits to the root README.MD file are allowed +- No edits to the root README.md file are allowed -The root README.md file is auto generated by a combination of GitHub and ServiceNow workflows. Any changes directly to this file will immediately be overwritten, therefore any contributions directly to this file are useless. +The root README.md file is auto generated by a combination of GitHub and ServiceNow workflows. Any changes directly to this file will immediately be overwritten, therefore, any contributions made directly to this file will not be preserved. -Instead, contributions should be directed to this file: [.github/templates/rootreadmetemplate.md](https://github.com/ServiceNowDevProgram/Hacktoberfest/blob/4712587c2c974b0ca33531fe18b5e0d8279f19fa/.github/templates/rootreadmetemplate.md). This file is used to generate most of the README.md file \ No newline at end of file +Instead, contributions should be directed to this file: [.github/templates/rootreadmetemplate.md](https://github.com/ServiceNowDevProgram/Hacktoberfest/blob/4712587c2c974b0ca33531fe18b5e0d8279f19fa/.github/templates/rootreadmetemplate.md). This file is used to generate most of the README.md file.