{"id":16662129,"url":"https://github.com/msarmadqadeer/java-tasks","last_synced_at":"2025-10-14T18:32:31.019Z","repository":{"id":111105127,"uuid":"453639803","full_name":"MSarmadQadeer/java-tasks","owner":"MSarmadQadeer","description":"These are all java tasks that I created during studying programming fundamentals subject.","archived":false,"fork":false,"pushed_at":"2022-01-30T10:39:42.000Z","size":16,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-12T21:48:39.697Z","etag":null,"topics":["java","java-tasks","programming-fundamentals","semester-2"],"latest_commit_sha":null,"homepage":"","language":"Java","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/MSarmadQadeer.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,"publiccode":null,"codemeta":null}},"created_at":"2022-01-30T09:41:28.000Z","updated_at":"2022-01-30T10:41:30.000Z","dependencies_parsed_at":"2023-04-18T17:06:00.751Z","dependency_job_id":null,"html_url":"https://github.com/MSarmadQadeer/java-tasks","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/MSarmadQadeer/java-tasks","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MSarmadQadeer%2Fjava-tasks","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MSarmadQadeer%2Fjava-tasks/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MSarmadQadeer%2Fjava-tasks/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MSarmadQadeer%2Fjava-tasks/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/MSarmadQadeer","download_url":"https://codeload.github.com/MSarmadQadeer/java-tasks/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MSarmadQadeer%2Fjava-tasks/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279020352,"owners_count":26086866,"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","status":"online","status_checked_at":"2025-10-14T02:00:06.444Z","response_time":60,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["java","java-tasks","programming-fundamentals","semester-2"],"created_at":"2024-10-12T10:37:05.094Z","updated_at":"2025-10-14T18:32:31.002Z","avatar_url":"https://github.com/MSarmadQadeer.png","language":"Java","readme":"# java-tasks\n\nThese are all java tasks that I created during studying programming fundamentals subject.\n\n## fun fact :joy:\n\nIn the above Java files, there is a file _`SarmadiList.java`_.\n\n### story behind _`SarmadiList.java`_\n\nWhen we studied **Arrays in Java**, we came to know that in Java the **length of Arrays is immutable (fixed)**. And we cannot append any item to Arrays in Java as we do in Lists in Python.\n\nAt that time I created a method in Java that takes two arguments and returns a new array.\n\n1. **1st Argument** is an Array in which I want to insert another entry.\n2. **2nd Argument** is a Number that I want to insert at the end.\n\n```java\npublic static int[] append(int[] list, int value) {\n    int[] newList = new int[list.length + 1];\n    for (int i = 0; i \u003c list.length; i++) {\n        newList[i] = list[i];\n    }\n    newList[newList.length - 1] = value;\n    return newList;\n}\n```\n\nWhat it does is that it creates a new Array with the length of 1+ in the length of the previous Array. After that, it inserts all the values of a previous Array into the new Array, and the number that it takes as a 2nd argument is inserted at the last index of the new Array. Finally, it returns the new Array.\n\nAfter doing this, I felt like I conquered something :rofl:.\n\n### what I learned :sparkles:\n\nWhen I show this to my teacher, he told me that by doing this I am creating a new Array in memory and not appending it at the end of that previous Array, which is not memory efficient.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmsarmadqadeer%2Fjava-tasks","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmsarmadqadeer%2Fjava-tasks","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmsarmadqadeer%2Fjava-tasks/lists"}