[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"nav-categories":3,"article-different-types-of-sort-in-java-you-must-know":70},{"data":4},[5,37,57,64],{"name":6,"slug":7,"categories":8},"Productivity","productivity",[9,13,17,21,25,29,33],{"id":10,"title":11,"slug":12},17,"Branding","branding",{"id":14,"title":15,"slug":16},19,"Marketing","marketing",{"id":18,"title":19,"slug":20},20,"Work","work",{"id":22,"title":23,"slug":24},34,"Community","community",{"id":26,"title":27,"slug":28},21,"For newbies","for-newbies",{"id":30,"title":31,"slug":32},24,"Investment","investment",{"id":34,"title":35,"slug":36},22,"Finance","finance",{"name":38,"slug":39,"categories":40},"Tech","tech",[41,45,49,53],{"id":42,"title":43,"slug":44},28,"Technology","technology",{"id":46,"title":47,"slug":48},32,"Artificial Intelligence","artificial-intelligence",{"id":50,"title":51,"slug":52},26,"Security and protection","security-and-protection",{"id":54,"title":55,"slug":56},31,"YouTube Blog","youtube-blog",{"name":58,"slug":59,"categories":60},"News","news",[61],{"id":62,"title":58,"slug":63},18,"quasanews",{"name":65,"slug":66,"categories":67},"Business","business",[68],{"id":69,"title":65,"slug":66},16,{"post":71,"published_news":95,"popular_news":163,"categories":233},{"title":72,"description":73,"meta_title":72,"meta_description":73,"meta_keywords":74,"text":75,"slug":76,"created_at":77,"publish_at":78,"formatted_created_at":79,"category_id":18,"links":80,"view_type":84,"video_url":82,"views":85,"likes":86,"lang":87,"comments_count":88,"category":89},"Different Types Of Sort In Java You Must Know","There are many different types of sorting algorithms in Java, each with its own strengths and weaknesses.","Types Of Sort In Java, it","\u003Cp>Hello!\u003C/p>\n\n\u003Cp>There are many different types of sorting algorithms in \u003Ca href=\"https://quasa.io/media/what-is-a-great-javascript-real-time-chart-library\">Java\u003C/a>, each with its own strengths and weaknesses. Here are some of the most commonly used sorting algorithms in Java:\u003C/p>\n\n\u003Ch3>\u003Cstrong>Bubble Sort:&nbsp;\u003C/strong>\u003C/h3>\n\n\u003Cp>This is a simple sorting algorithm that repeatedly steps through the list to be sorted, compares adjacent elements, and swaps them if they are in the wrong order. It has a time complexity of O(n^2) and is not efficient for large lists.\u003C/p>\n\n\u003Cp>Bubble Sort is a simple sorting algorithm that repeatedly iterates through the list to be sorted and compares adjacent elements, swapping them if they are in the wrong order. The algorithm gets its name from the way smaller elements &ldquo;bubble&rdquo; to the top of the list.\u003C/p>\n\n\u003Cp>Here is how the&nbsp;\u003Cstrong>bubble sort java\u003C/strong>&nbsp;algorithm works:\u003Cpicture class=\"image-align-right\">\u003Csource srcset=\"https://cdn.quasa.io/photos/foto-15/100-5.webp\" type=\"image/webp\">\u003Cimg class=\"image-align-right\" height=\"300\" src=\"https://cdn.quasa.io/photos/foto-15/100-5.jpeg\" width=\"300\" / alt=\"Different Types Of Sort In Java You Must Know\" loading=\"lazy\">\u003C/picture>\u003C/p>\n\n\u003Col>\n\t\u003Cli>Starting from the first element, compare the first two elements of the list. If the first element is greater than the second element, swap them.\u003C/li>\n\t\u003Cli>Move to the next pair of elements, i.e. elements 2 and 3, and repeat step 1.\u003C/li>\n\t\u003Cli>Continue this process until the end of the list is reached.\u003C/li>\n\t\u003Cli>Now, the largest element is at the end of the list.\u003C/li>\n\t\u003Cli>Repeat steps 1-4 for the remaining elements in the list, excluding the last element that was already sorted.\u003C/li>\n\t\u003Cli>Continue this process until the entire list is sorted.\u003C/li>\n\u003C/ol>\n\n\u003Cp>\u003Cstrong>bubble sort \u003Ca href=\"https://quasa.io/media/nine-courses-you-can-take-to-become-a-javascript-wizard\">java\u003C/a>\u003C/strong>&nbsp;has a time complexity of O(n^2), which makes it inefficient for large datasets. However, it is simple to understand and implement and can be useful for small datasets or as an educational tool to understand sorting algorithms.\u003C/p>\n\n\u003Ch3>Selection Sort:\u003C/h3>\n\n\u003Cp>This&nbsp;algorithm sorts&nbsp;an array by repeatedly finding the minimum element from the unsorted part of the array and putting it at the beginning. It has a time complexity of O(n^2) and is not efficient for large lists.\u003C/p>\n\n\u003Cp>Selection Sort is a simple sorting algorithm that repeatedly finds the minimum element from the unsorted part of the list and places it at the beginning. The algorithm maintains two sub-lists, one that is sorted and another that is unsorted.\u003C/p>\n\n\u003Cp>Here is how the Selection Sort algorithm works:\u003Cpicture class=\"image-align-right\">\u003Csource srcset=\"https://cdn.quasa.io/photos/foto-15/100-10.webp\" type=\"image/webp\">\u003Cimg class=\"image-align-right\" height=\"183\" src=\"https://cdn.quasa.io/photos/foto-15/100-10.jpeg\" width=\"275\" / alt=\"Different Types Of Sort In Java You Must Know\" loading=\"lazy\">\u003C/picture>\u003C/p>\n\n\u003Col>\n\t\u003Cli>Find the minimum element in the unsorted part of the list.\u003C/li>\n\t\u003Cli>Swap the minimum element with the first element of the unsorted list.\u003C/li>\n\t\u003Cli>Move the boundary of the sorted sub-list one element to the right.\u003C/li>\n\t\u003Cli>Repeat steps 1-3 until the entire list is sorted.\u003C/li>\n\u003C/ol>\n\n\u003Cp>Selection Sort has a time complexity of O(n^2), which makes it inefficient for large datasets. However, it is simple to understand and implement and can be useful for small datasets or as an educational tool to understand sorting algorithms.\u003C/p>\n\n\u003Cp>One disadvantage of Selection Sort is that it does not handle repeated elements well. If there are many repeated elements in the list, they will be swapped multiple times, resulting in unnecessary work. Another disadvantage is that it is not a stable sort, meaning that the order of equal elements may not be preserved.\u003C/p>\n\n\u003Ch3>Insertion Sort:\u003C/h3>\n\n\u003Cp>This algorithm works the way many people sort cards in their hands. It iterates through the list and removes one element at a time, finds the location it belongs within the sorted list and inserts it there. It has a time complexity of O(n^2) and is not efficient for large lists in the&nbsp;\u003Cstrong>java program compiler\u003C/strong>.\u003C/p>\n\n\u003Cp>Insertion Sort is a simple sorting algorithm that works by building a sorted list one element at a time. It iterates through the list and each element is compared to the elements that come before it. If the previous element is greater than the current element, then the two elements are swapped. This process is repeated until the entire list is sorted.\u003C/p>\n\n\u003Cp>Here is how the Insertion Sort algorithm works:\u003Cpicture class=\"image-align-right\">\u003Csource srcset=\"https://quasa.io/storage/photos/фото 15/.webp\" type=\"image/webp\">\u003Cimg class=\"image-align-right\" height=\"200\" src=\"https://quasa.io/storage/photos/фото 15/.jpeg\" width=\"300\" / alt=\"Different Types Of Sort In Java You Must Know\" loading=\"lazy\">\u003C/picture>\u003C/p>\n\n\u003Col>\n\t\u003Cli>Assume that the first element in the list is already sorted.\u003C/li>\n\t\u003Cli>Take the next element and compare it with the sorted list, shifting the elements if necessary.\u003C/li>\n\t\u003Cli>Repeat step 2 until the entire list is sorted.\u003C/li>\n\u003C/ol>\n\n\u003Cp>Insertion Sort has a time complexity of O(n^2), which makes it inefficient for large datasets. However, it is efficient for small datasets and for almost-sorted datasets, meaning that the elements are already partially sorted.\u003C/p>\n\n\u003Cp>One advantage of Insertion Sort is that it is a stable sort, meaning that the order of equal elements is preserved. Another advantage is that it is an in-place sort, meaning that it does not require&nbsp;additional memory&nbsp;to store the sorted list.\u003C/p>\n\n\u003Ch3>Merge Sort:\u003C/h3>\n\n\u003Cp>This is a divide-and-conquer algorithm that divides an array into two halves, recursively sorts the two halves, and then merges the sorted halves. It has a time complexity of O(n log n) and is efficient for large lists.\u003C/p>\n\n\u003Cp>Merge Sort is a divide-and-conquer sorting algorithm that works by breaking down the list into smaller sub-lists, sorting those sub-lists, and then merging them back together in the correct order. The algorithm divides the list into halves repeatedly until it reaches the smallest unit, which is a list with only one element. The smaller lists are then merged together in the correct order using a merge function.\u003C/p>\n\n\u003Cp>Here is how the Merge Sort algorithm works:\u003Cpicture class=\"image-align-right\">\u003Csource srcset=\"https://cdn.quasa.io/photos/foto-1/0-fi-25.webp\" type=\"image/webp\">\u003Cimg class=\"image-align-right\" height=\"200\" src=\"https://cdn.quasa.io/photos/foto-1/0-fi-25.jpeg\" width=\"300\" / alt=\"Different Types Of Sort In Java You Must Know\" loading=\"lazy\">\u003C/picture>\u003C/p>\n\n\u003Col>\n\t\u003Cli>Divide the list into two halves until each sub-list contains only one element.\u003C/li>\n\t\u003Cli>Compare the first elements of the two sub-lists and merge them into a new list in the correct order.\u003C/li>\n\t\u003Cli>Repeat step 2 until all the elements are merged back together into a sorted list.\u003C/li>\n\u003C/ol>\n\n\u003Cp>Merge Sort has a time complexity of O(n log n), which makes it efficient for large datasets. It is also a stable sort, meaning that the order of equal elements is preserved. However, it requires additional memory to store the sub-lists during the sorting process, which can make it inefficient for large datasets with limited memory.\u003C/p>\n\n\u003Cp>One advantage of Merge Sort is that it can be easily parallelized, meaning that it can be split into multiple threads and executed simultaneously on multiple processors, further&nbsp;improving its efficiency.\u003C/p>\n\n\u003Cp>These are just a few of the many sorting algorithms available in the&nbsp;\u003Cstrong>java program compiler\u003C/strong>. The choice of algorithm depends on the specific needs of the application, the size of the dataset, and the desired performance characteristics.\u003C/p>\n\n\u003Cp>Thank you!\u003Cbr />\nJoin us on social media!\u003Cbr />\nSee you!\u003C/p>","different-types-of-sort-in-java-you-must-know","2024-01-02T08:44:26.000000Z","2024-01-02T12:30:00.000000Z","02.01.2024",{"image":81,"image_webp":82,"thumb":83,"thumb_webp":83},"https://cdn.quasa.io/images/news/khIhUoLdDRL6IBgGLYtu78zsjxs80QmBcSil8y2H.webp",null,"https://cdn.quasa.io/thumbs/news-thumb/images/news/khIhUoLdDRL6IBgGLYtu78zsjxs80QmBcSil8y2H.webp","large",2053,7,"en",0,{"id":18,"title":19,"slug":20,"meta_title":90,"meta_description":91,"meta_keywords":92,"deleted_at":82,"created_at":93,"updated_at":94,"lang":87},"Quasa Media's blog about Growth Hacking in action","Exclusive life hacks on how to choose a career and be productive in any job.","Freelance, business, startup, Survive As a Freelance Developer","2021-09-03T20:21:41.000000Z","2024-08-25T15:40:14.000000Z",[96,112,124,137,150],{"title":97,"description":98,"slug":99,"created_at":100,"publish_at":101,"formatted_created_at":102,"category":103,"links":104,"view_type":109,"video_url":82,"views":110,"likes":88,"lang":87,"comments_count":88,"is_pinned":111},"Two Seemingly Contradictory Thoughts About AI Transformation","The reality is more nuanced and more interesting: a gradual but substantial restructuring of white-collar work, with meaningful productivity gains and moderate headcount adjustments spread over several years.","two-seemingly-contradictory-thoughts-about-ai-transformation","2026-04-10T17:15:34.000000Z","2026-04-14T09:06:00.000000Z","14.04.2026",{"title":19,"slug":20},{"image":105,"image_webp":106,"thumb":107,"thumb_webp":108},"https://cdn.quasa.io/images/news/KZSll5P8ZAZHN96B82NQBSU6YKs8suxhPjm50Z56.jpg","https://cdn.quasa.io/images/news/KZSll5P8ZAZHN96B82NQBSU6YKs8suxhPjm50Z56.webp","https://cdn.quasa.io/thumbs/news-thumb/images/news/KZSll5P8ZAZHN96B82NQBSU6YKs8suxhPjm50Z56.jpg","https://cdn.quasa.io/thumbs/news-thumb/images/news/KZSll5P8ZAZHN96B82NQBSU6YKs8suxhPjm50Z56.webp","small",8,false,{"title":113,"description":114,"slug":115,"created_at":116,"publish_at":117,"formatted_created_at":102,"category":118,"links":119,"view_type":109,"video_url":82,"views":18,"likes":88,"lang":87,"comments_count":88,"is_pinned":111},"Stop Projecting Human Qualities onto AI — How to Actually Build Effective AI Systems","The biggest mistake you can make in 2026 is trying to turn an LLM into a digital employee.","stop-projecting-human-qualities-onto-ai-how-to-actually-build-effective-ai-systems","2026-04-10T17:04:18.000000Z","2026-04-14T06:54:00.000000Z",{"title":19,"slug":20},{"image":120,"image_webp":121,"thumb":122,"thumb_webp":123},"https://cdn.quasa.io/images/news/LOfwyulrmZCf8RKjFZq3MXf4PFBXKTitoTcwR6NS.jpg","https://cdn.quasa.io/images/news/LOfwyulrmZCf8RKjFZq3MXf4PFBXKTitoTcwR6NS.webp","https://cdn.quasa.io/thumbs/news-thumb/images/news/LOfwyulrmZCf8RKjFZq3MXf4PFBXKTitoTcwR6NS.jpg","https://cdn.quasa.io/thumbs/news-thumb/images/news/LOfwyulrmZCf8RKjFZq3MXf4PFBXKTitoTcwR6NS.webp",{"title":125,"description":126,"slug":127,"created_at":128,"publish_at":129,"formatted_created_at":102,"category":130,"links":131,"view_type":109,"video_url":82,"views":136,"likes":88,"lang":87,"comments_count":88,"is_pinned":111},"You’re Not Building AI Systems — You’re Discovering Them","Here’s a truth most people still refuse to accept when they try to “implement AI” in their business:\nYou are not building a system.\nYou are discovering one.","you-re-not-building-ai-systems-you-re-discovering-them","2026-04-10T16:49:42.000000Z","2026-04-14T03:40:00.000000Z",{"title":27,"slug":28},{"image":132,"image_webp":133,"thumb":134,"thumb_webp":135},"https://cdn.quasa.io/images/news/BiGQ4ooOG2yf5o52eoSEI1c3CBxvOtHxAO1QizJn.jpg","https://cdn.quasa.io/images/news/BiGQ4ooOG2yf5o52eoSEI1c3CBxvOtHxAO1QizJn.webp","https://cdn.quasa.io/thumbs/news-thumb/images/news/BiGQ4ooOG2yf5o52eoSEI1c3CBxvOtHxAO1QizJn.jpg","https://cdn.quasa.io/thumbs/news-thumb/images/news/BiGQ4ooOG2yf5o52eoSEI1c3CBxvOtHxAO1QizJn.webp",37,{"title":138,"description":139,"slug":140,"created_at":141,"publish_at":141,"formatted_created_at":142,"category":143,"links":144,"view_type":84,"video_url":82,"views":149,"likes":88,"lang":87,"comments_count":88,"is_pinned":111},"5 Best AI Video Generators to Create Viral Videos in 2026","Discover the 5 best AI video generator tools in 2026, including Pollo AI, Vidu AI, Luma AI, Seedance 2.0, and Runway. Explore features, use cases, and how each platform transforms video creation.","5-best-ai-video-generators-to-create-viral-videos-in-2026","2026-04-13T12:44:33.000000Z","13.04.2026",{"title":47,"slug":48},{"image":145,"image_webp":146,"thumb":147,"thumb_webp":148},"https://cdn.quasa.io/images/news/duns6zBmgrIjP63CFihBCyqTAJYJhxGtA1y63wAU.jpg","https://cdn.quasa.io/images/news/duns6zBmgrIjP63CFihBCyqTAJYJhxGtA1y63wAU.webp","https://cdn.quasa.io/thumbs/news-thumb/images/news/duns6zBmgrIjP63CFihBCyqTAJYJhxGtA1y63wAU.jpg","https://cdn.quasa.io/thumbs/news-thumb/images/news/duns6zBmgrIjP63CFihBCyqTAJYJhxGtA1y63wAU.webp",121,{"title":151,"description":152,"slug":153,"created_at":154,"publish_at":155,"formatted_created_at":142,"category":156,"links":157,"view_type":109,"video_url":82,"views":162,"likes":88,"lang":87,"comments_count":88,"is_pinned":111},"How I Automated My Basic Marketing Tasks with AI (And 4x’d My Efficiency)","I used to spend hours every week on repetitive marketing work: sizing markets, building pitch decks, crunching ad data, and writing Reels scripts. It was necessary, but it sucked the life out of my day.","how-i-automated-my-basic-marketing-tasks-with-ai-and-4x-d-my-efficiency","2026-04-10T16:25:49.000000Z","2026-04-13T11:15:00.000000Z",{"title":19,"slug":20},{"image":158,"image_webp":159,"thumb":160,"thumb_webp":161},"https://cdn.quasa.io/images/news/K8Ny6XKxqndaPMAb6bVEOd7P3FajpGzdnfBSYA20.jpg","https://cdn.quasa.io/images/news/K8Ny6XKxqndaPMAb6bVEOd7P3FajpGzdnfBSYA20.webp","https://cdn.quasa.io/thumbs/news-thumb/images/news/K8Ny6XKxqndaPMAb6bVEOd7P3FajpGzdnfBSYA20.jpg","https://cdn.quasa.io/thumbs/news-thumb/images/news/K8Ny6XKxqndaPMAb6bVEOd7P3FajpGzdnfBSYA20.webp",127,[164,177,192,204,219],{"title":165,"description":166,"slug":167,"created_at":168,"publish_at":169,"formatted_created_at":170,"category":171,"links":172,"view_type":109,"video_url":82,"views":175,"likes":176,"lang":87,"comments_count":88,"is_pinned":111},"The Anatomy of an Entrepreneur","Entrepreneur is a French word that means an enterpriser. Enterprisers are people who undertake a business or enterprise with the chance of earning profits or suffering from loss.","the-anatomy-of-an-entrepreneur","2021-08-04T15:18:21.000000Z","2025-12-14T06:09:00.000000Z","14.12.2025",{"title":65,"slug":66},{"image":173,"image_webp":82,"thumb":174,"thumb_webp":174},"https://cdn.quasa.io/images/news/mVsXPTMuHZuI7UXCsENgL1Qwp1uSOf7Rz3uVPMfm.webp","https://cdn.quasa.io/thumbs/news-thumb/images/news/mVsXPTMuHZuI7UXCsENgL1Qwp1uSOf7Rz3uVPMfm.webp",70131,2,{"title":178,"description":179,"slug":180,"created_at":181,"publish_at":182,"formatted_created_at":183,"category":184,"links":185,"view_type":84,"video_url":82,"views":190,"likes":191,"lang":87,"comments_count":88,"is_pinned":111},"Advertising on QUASA","QUASA MEDIA is read by more than 400 thousand people a month. We offer to place your article, add a link or order the writing of an article for publication.","advertising-on-quasa","2022-07-06T07:33:02.000000Z","2025-12-15T17:33:02.000000Z","15.12.2025",{"title":58,"slug":63},{"image":186,"image_webp":187,"thumb":188,"thumb_webp":189},"https://cdn.quasa.io/images/news/45SvmdsTQbiyc3nxgbyHY1mpVbisYyub2BCHjqBL.jpg","https://cdn.quasa.io/images/news/45SvmdsTQbiyc3nxgbyHY1mpVbisYyub2BCHjqBL.webp","https://cdn.quasa.io/thumbs/news-thumb/images/news/45SvmdsTQbiyc3nxgbyHY1mpVbisYyub2BCHjqBL.jpg","https://cdn.quasa.io/thumbs/news-thumb/images/news/45SvmdsTQbiyc3nxgbyHY1mpVbisYyub2BCHjqBL.webp",69878,4,{"title":193,"description":194,"slug":195,"created_at":196,"publish_at":197,"formatted_created_at":198,"category":199,"links":200,"view_type":109,"video_url":82,"views":203,"likes":191,"lang":87,"comments_count":88,"is_pinned":111},"What is a Startup?","A startup is not a new company, not a tech company, nor a new tech company. You can be a new tech company, if your goal is not to grow high and fast; then, you are not a startup. ","what-is-a-startup","2021-08-04T12:05:17.000000Z","2025-12-17T13:02:00.000000Z","17.12.2025",{"title":65,"slug":66},{"image":201,"image_webp":82,"thumb":202,"thumb_webp":202},"https://cdn.quasa.io/images/news/EOsQhSW3VXyG7a6NPdE1oZd00xfJXe3bjY5aJGb7.webp","https://cdn.quasa.io/thumbs/news-thumb/images/news/EOsQhSW3VXyG7a6NPdE1oZd00xfJXe3bjY5aJGb7.webp",67542,{"title":205,"description":206,"slug":207,"created_at":208,"publish_at":209,"formatted_created_at":210,"category":211,"links":212,"view_type":109,"video_url":82,"views":217,"likes":176,"lang":87,"comments_count":218,"is_pinned":111},"Top 5 Tips to Make More Money as a Content Creator","Content creators are one of the most desired job titles right now. Who wouldn’t want to earn a living online?","top-5-tips-to-make-more-money-as-a-content-creator","2022-01-17T17:31:51.000000Z","2026-01-17T11:30:00.000000Z","17.01.2026",{"title":19,"slug":20},{"image":213,"image_webp":214,"thumb":215,"thumb_webp":216},"https://cdn.quasa.io/images/news/gP8kiumBPpJmQv6SMieXiX1tDetx43VwFfO1P4Ca.jpg","https://cdn.quasa.io/images/news/gP8kiumBPpJmQv6SMieXiX1tDetx43VwFfO1P4Ca.webp","https://cdn.quasa.io/thumbs/news-thumb/images/news/gP8kiumBPpJmQv6SMieXiX1tDetx43VwFfO1P4Ca.jpg","https://cdn.quasa.io/thumbs/news-thumb/images/news/gP8kiumBPpJmQv6SMieXiX1tDetx43VwFfO1P4Ca.webp",41580,1,{"title":220,"description":221,"slug":222,"created_at":223,"publish_at":224,"formatted_created_at":225,"category":226,"links":227,"view_type":84,"video_url":82,"views":232,"likes":176,"lang":87,"comments_count":88,"is_pinned":111},"8 Logo Design Tips for Small Businesses","Your logo tells the story of your business and the values you stand for.","8-logo-design-tips-for-small-businesses","2021-12-04T21:59:52.000000Z","2025-05-05T03:30:00.000000Z","05.05.2025",{"title":15,"slug":16},{"image":228,"image_webp":229,"thumb":230,"thumb_webp":231},"https://cdn.quasa.io/images/news/Wbx2NtS1CnTupgoQbpFMGspJ5jm4uob2hDOq33r0.jpg","https://cdn.quasa.io/images/news/Wbx2NtS1CnTupgoQbpFMGspJ5jm4uob2hDOq33r0.webp","https://cdn.quasa.io/thumbs/news-thumb/images/news/Wbx2NtS1CnTupgoQbpFMGspJ5jm4uob2hDOq33r0.jpg","https://cdn.quasa.io/thumbs/news-thumb/images/news/Wbx2NtS1CnTupgoQbpFMGspJ5jm4uob2hDOq33r0.webp",40727,[234,235,236,237,238,239,240,241,242,243,244,245,246],{"title":23,"slug":24},{"title":47,"slug":48},{"title":55,"slug":56},{"title":43,"slug":44},{"title":51,"slug":52},{"title":31,"slug":32},{"title":35,"slug":36},{"title":27,"slug":28},{"title":19,"slug":20},{"title":15,"slug":16},{"title":58,"slug":63},{"title":11,"slug":12},{"title":65,"slug":66}]