The Fastest Way to Sort Anything



The Fastest Way to Sort Anything



Divide and Conquer, like a programmer.


If I gave you a deck of cards and asked you to sort them from low to high card, how would you do it? Most non-programmers fan out the cards and proceed to move cards forward and back until things finally come together. While that will get the job done, it's not the fastest way to do it.

What programmers do is try to split whatever we're trying to sort into smaller sections, then sort each section one by one, and finally merge the sections at the end. For example, by splitting a deck of cards into two piles of 26, or 4 piles of 13, each of the piles will take a fraction of the time to sort because you'll be doing fewer comparisons to determine the positions of each individual card.

Merging the piles at the end is a breeze... it's sort of like playing solitaire. Once you've sorted all the stacks at the bottom, it takes seconds to merge them into the 4 stacks at the end.

This method works for sorting just about anything.

, Founder

(Reply N/A) (Edit Topic N/A) (Like Topic N/A) [0 ] 5309 Views

Related Posts

Productivity(72)
Sorting(1)
Tips(34)


Subscribe Via RSS
No Comments

Leave a Comment

Title (optional)
To post your comment, just log in or Instant Register

Instant Registration / Login

Email Address (Required):

You are not logged in.


Top 25 Posts
* Note: The ideas on "Idea of the Day" were posted without any formal research into existing inventions.

In some cases, patents may already exist for these ideas, in other cases, there may not be any existing patents and you are free to develop and explore the viability of developing and patenting the ideas.

The authors make no claim that any of the ideas are safe, practical, or suitable for any particular purpose. You are responsible for the results of trying, developing, patenting or using any of the ideas on this site.

For some people, our ideas are just an interesting read, but our goal is to encourage you to take action. If you see an idea that you like, do something with it... Take action.


- Joe
Subscribe Via RSS


Categories

(2)
Entrepreneur(1)
Entrepreneurs(1)
3D Printing(1)
4K(3)
7-Eleven(1)
Accessories(2)
ACH(1)
Acid Indigstion(1)
Advertising(1)
Airlines(3)
AirPods(1)
Airports(1)
Alexa(5)
Algorithms(3)
Alka-Seltzer(2)
Amazon(30)
Amazon Alexa(1)
Amazon Echo(8)
Android(18)
Animals(1)
Antacids(2)
Anti-Viruses(1)
App(1)
App Store(2)
App Stores(3)
Apple(174)
Apple Radio(2)
Apple TV(16)
Apple Watch(17)
Apples(1)
Apps(60)
Art(1)
ATM(2)
ATMs(1)
Atticus Finch(1)
Auctions(1)
Audible(3)
Audio(4)
Audiobooks(3)
Autmotive(1)
Auto(1)
Autocorrect(1)
Automation(1)
Automotiv(1)
Automotive(19)
Awards(1)
Awareness(1)
Backups(4)
Bacon(1)
Bad Ideas(1)
Baking Soda(1)
Balogna(1)
Bank Fees(1)
Banking(20)
Banks(3)
Baseball(4)
Baseball Cards(2)
Basketball(1)
Bathroom(3)
Bathrooms(12)
Batteries(2)
Behind the Scenes(5)
Ben Kenobi(1)
Beverages(3)
Bible(1)
Big Brother(1)
Big Data(4)
Bing(5)
Bio Foods(1)
Bitcoins(1)
Blog(1)
Bloom County(1)
Bluetooth(6)
Books(3)
Bottled Water(1)
Brain Science(2)
Brainstorming(2)
Branding(3)
Bread(1)
Broadway(1)
Browsers(5)
Bugs(1)
Bumper Guards(1)
Bundleware(2)
Burger King(2)
Business(35)
Business Cards(1)
Business Ideas(2)
Businesses(2)
Butter(1)
C-3PO(1)
Cable TV(9)
Camera Makers(1)
Cameras(1)
Car Makers(5)
Car Rentals(1)
Car Wash(1)
Cars(46)
Cash(1)
Casinos(1)
Cat Videos(1)
Cats(5)
CB(1)
Celebrity(1)
Cereal(1)
Chat(2)
Checking Accounts(2)
Cheese(1)
Cheez Doodles(1)
Chewbacca(1)
Children(1)
Chinese Culture(1)
Chinese Food(2)
Chipotle(1)
Chrome(3)
Chromecast(1)
Clean Streets(2)
Cleaning(6)
Cleanliness(16)
Cleanup(1)
Cliches.Fun(1)
ClickBait(1)
Clinton(1)
Clothing(4)
Cloud(8)
Cloud Backups(1)
Cloud Computing(1)
Clutter(12)
Coats(1)
Coffee(2)
Cola(1)
Collaboration(1)
Collectibles(3)
Collecting(2)
Comedy(3)
Comics(1)
Commercials(1)
Common Sense(40)
Communication(3)
Companies(1)
Compatibility(1)
Computers(6)
Computing(108)
Condiments(1)
Consumer Awareness(2)
Consumers(1)
Content Marketing(1)
Contract(1)
Convenience(1)
Cookies(4)
Cooking(3)
Costco(1)
Coupons(1)
Cracker Jack(1)
Creativity(8)
Credit Cards(4)
Crime(1)
Crowds(1)
Cup Sizes(1)
Dance Clubs(1)
Darth Vader(3)
Daylight Savings Time(2)
Debates(1)
Declutter(1)
Defense(1)
Delivery(1)
Dell(2)
Design(1)
Dieting(1)
Digital Media(17)
Digital Rights(3)
Disabilities(1)
Disney(2)
DIY(3)
DMV(1)
DNS(1)
Dogs(3)
Domains(4)
Drinks(3)
Driver Safety(1)
Drivers(1)
Driving(27)
Dropbox(4)
Dumping(1)
Dusters(1)
DVD(1)
E-Ink(1)
E-ZPass(4)
Earworms(1)
eBay(2)
Echo(4)
Ecology(1)
Economy(1)
Education(8)
Efficiency(1)
Election(10)
Elections(2)
Electoral College(1)
Electricity(1)
Electronics(8)
Elevator(1)
Email(34)
Emojis(1)
Encryption(1)
Energy Savings(1)
English(1)
English Language(1)
Entertainment(11)
Entrepreneur(1)
Equality(2)
Ergonomics(1)
Essentialism(2)
Excel(1)
Face Recognition(1)
Facebook(14)
FaceTime(7)
Fairness(1)
Fake IRS(1)
Fake News(1)
Families(1)
Family(3)
Family Values(1)
Famous Amos(1)
Fans(2)
Fashion(2)
Fast Food(33)
Fax Machines(1)
FBI(1)
FDA(6)
Fear(1)
FedEx(3)
Feedback(1)
Festivus(1)
Finaince(1)
Finance(21)
Fire Prevention(2)
Fire Trucks(1)
FireFox(3)
FitBit(3)
Fitness(2)
Fixes(1)
Flash Drives(1)
Flash Storage(1)
Food(59)
Food Labels(1)
Food Safety(1)
Foodie(16)
Foodies(5)
Football(1)
Fraud(5)
Fun(39)
Fun Fact(1)
Fundraising(2)
Funny(14)
Furniture(1)
Fusion(1)
FYI(1)
Gadgets(6)
Game Consoles(1)
Games(1)
Gaming(2)
Garage Band(1)
Garage Doors(1)
Garbage(1)
Garden State Parkway(1)
Gas(2)
Gas Detectors(1)
Geeks(2)
Generation Gap(1)
Generic Drugs(1)
Gifts(1)
Gluten Free(1)
Gmail(27)
Golf(4)
Google(31)
Google Radar(1)
Government(4)
Government Abuse(1)
GPS(8)
Graphic Design(1)
Greeting Cards(2)
Groceries(2)
GTD(2)
Gun Control(1)
Gun Permits(1)
Guns(1)
Hacking(4)
Hand Dryer(1)
Hand Sanitizers(3)
Hashtags(2)
Hats(2)
HDMI(1)
Headsets(1)
Health(19)
Healthcare(8)
Hearing Aids(1)
HFS+(1)
Hipsters(1)
Hiring(1)
History(2)
Hoarding(8)
Hockey(1)
Holidays(2)
Home(1)
Home Automation(1)
Home Improvement(9)
Home Theater(1)
Honesty(2)
Horror Movies(1)
Hospitals(5)
Hotels(2)
Household(1)
How-To(1)
Howard Stern(3)
HP(1)
HTML(1)
Hulk Hogan(1)
Human Resources(1)
Humor(1)
Hygiene(1)
Ice Cream(3)
Iced Tea(3)
Icee(1)
iCloud(5)
ID Cards(2)
Idea of the Day(2)
Ideas(10)
Identity Protection(1)
Identity Theft(5)
Immigration(1)
Improvements(106)
Improvvements(1)
Imrovements(1)
Imrpovements(1)
Imrprovements(3)
Inspiration(47)
Instagram(2)
Integrity(1)
Intel(1)
Internet(16)
Internet Of Things(1)
Internet Radio(1)
Internet Trolls(2)
Interpreters(1)
Inventing(1)
Invention(11)
Inventions(65)
iOS(87)
IOT(1)
iPad(10)
iPhone(62)
iPod(3)
Iron Man(1)
iTunes(5)
iTunes Radio(1)
Jackass(1)
James Bond(1)
Java(1)
Jerry Seinfeld(1)
Jobs(5)
Joe Crescenzi(1)
Joke(1)
Jumper Cables(1)
Junk(1)
Kaizen(1)
Ketchonnaise(1)
Keyboard(2)
Keyboards(6)
Keys(1)
Keywords(1)
Kids(2)
Kindle(6)
Kindness(1)
Kitchens(1)
Klondike Bars(1)
Kurt Vonnegut(1)
Landline Phones(1)
Language(2)
Laundry(1)
Lawnmowers(1)
Laws(10)
Leadership(2)
Lean(1)
Learning(1)
LEDs(1)
Legal(3)
Leonard Nimoy(1)
Libraries(1)
Life Lessons(2)
Light Bulbs(1)
Lightning(1)
LinkedIn(2)
Local(2)
Lottery(1)
Love(1)
Loyalty Cards(3)
Mac(33)
Mac vs Windows(1)
MacOS(12)
Macs(2)
Mailboxes(1)
Malls(1)
Management(2)
Manufacturing(1)
Maps(1)
Margarine(1)
Marketing(8)
Mashup(2)
Math(1)
Mattresses(2)
McDomalds(2)
McDonalds(20)
Meat(1)
Media(22)
Medical(3)
Medicine(1)
Meditation(1)
Memorial Day(1)
Memory(1)
Memory Cards(1)
Messaging(1)
Mexican Wall(1)
Mexico(1)
Microsoft(46)
Microsoft Office(3)
Military(1)
Military Spending(1)
Millennials(1)
Milli Vanilli(1)
Mini-Golf(1)
Minimalism(6)
Mission Impossible(1)
Mobile(89)
Money(2)
Money Saving(1)
Monitors(3)
Monty Python(2)
Motivation(1)
Movie(1)
Movies(44)
MP3(1)
Mr. Rogers(1)
MTV(1)
Music(10)
Names(1)
National Anthem(1)
Nerds(1)
Netflix(4)
Networks(6)
New Years(1)
News(7)
Newsfeeds(1)
Newspapers(1)
Nike(1)
Nintendo(1)
NJ(2)
Nose Picking(1)
Nostalgia(9)
Note Taking(1)
NTFS(1)
Nursing Homes(3)
Nurtrition(1)
Nutrition(6)
Nutrition Labels(1)
Nuts(1)
Observation(1)
OCD(1)
Office Equipment(1)
Office Supplies(1)
Offices(1)
Oldies(1)
Online Security(6)
Online Shopping(1)
OpenDNS(1)
Operating Systems(9)
Opinion(13)
Opinions(1)
Oracle(2)
Oreos(1)
Organization(2)
Organizing(2)
OS X(23)
OSX(2)
Overdrafts(2)
P2P(2)
Packaging(2)
Pandora(2)
Panera Bread(2)
Paper(1)
Paper Shredders(1)
Paper Towels(3)
Parental Controls(2)
Parenting(25)
Parking(2)
Parking Tickets(1)
Passwords(3)
Patriotism(1)
PayPal(1)
PC(3)
PDF(1)
Pedestrians(1)
Peer to Peer(1)
Periscope(1)
Personal(1)
Personalities(1)
Perspective(1)
Pete Rose(2)
Pets(7)
Philanthropy(1)
Philosophy(11)
Philosphy(1)
Phishing(1)
Phone Makers(2)
Phones(4)
Photo Labs(1)
Photography(36)
Photos App(1)
Photoshop(1)
Pizza(1)
Play Store(1)
Playstation(2)
Plumbing(1)
Podcasts(2)
Politics(21)
Polls(1)
Pop-Tarts(2)
Popularity(1)
Post-Its(1)
Potato Chips(1)
Power(1)
Power Adapters(2)
Presentations(1)
Price Stickers(1)
Printers(2)
Privacy(13)
Problem Solving(2)
Procrastination(2)
Product Ideas(1)
Product Packaging(1)
Product Safety(2)
Productivity(72)
Productivty(1)
Products I'd Love to See(1)
Psychology(6)
QR Codes(2)
R2-D2(1)
Radio(7)
Ransomware(1)
Rant(4)
Rants(99)
Rants.Cleanliness(1)
Reading(2)
Reagan(1)
Reality TV(3)
Recipe(1)
Recipes(3)
Recycling(1)
Red Sox(1)
Refridgerators(1)
Religion(1)
Reminders(1)
Remote Controls(5)
Remote Desktop(1)
Remotes(1)
Renal Cars(1)
Respect(1)
Responsive Design(2)
Restaurants(9)
Restroom(1)
Restrooms(5)
Restuarants(1)
Resumes(2)
Retail(2)
Reviews(3)
RFID(1)
Ring Tones(1)
Rip Offs(9)
Rip-Off(1)
Rip-Offs(6)
Road Rage(1)
Rodney Dangerfield(1)
Roku(1)
Ronald Reagan(1)
Running(1)
Safari(2)
Safes(1)
Safety(47)
Samsung(2)
Saturday Night Live(1)
Scams(2)
ScareWare(1)
Schools(3)
Science(11)
Science Fiction(8)
SD(1)
Search Engine Results Page(1)
Search Engines(14)
Security(42)
Security Questions(1)
Seinfeld(1)
Self-Driving(1)
Self-Driving Cars(3)
Selfie Sticks(1)
Senior Citizens(1)
SEO(4)
SERP(1)
Services(6)
Shaving(2)
Shipping(6)
Shoes(5)
Shopping(3)
Shopping Carts(1)
Silica(1)
Silly(2)
Singers(1)
Siri(10)
Sirius XM(1)
Skills(1)
Skype(2)
Slot Machines(1)
Slurpee(1)
Smart Devices(1)
SmartPhone(3)
SmartPhones(3)
Smoke Alarms(1)
SMS(2)
Snacks(2)
Snapple(2)
Snow(2)
Snuggies(1)
Social(1)
Social Experiment(1)
Social Media(38)
Society(1)
Sociology(1)
Soda(4)
Software(4)
Software Development(1)
Songs(1)
Sony(2)
Sorting(1)
Spam(9)
Spamalot(1)
Speakers(2)
Spirituality(1)
Sports(15)
Sportsmanship(1)
Spyware(1)
Staples(1)
Star Registries(1)
Star Trek(5)
Star Wars(34)
Starbucks(1)
Statistics(1)
Stickers(1)
Sticky Notes(1)
Storage(4)
Stormtroopers(1)
Stoves(1)
Streaming(5)
Students(1)
Subscriptions(3)
Subway(2)
Success(1)
Sunglasses(1)
Supermarkets(1)
Swiffer(2)
Tablets(2)
Talent Shows(1)
Talk Shows(3)
Target(1)
Tattoo(1)
Teamwork(1)
Tech(7)
Technology(90)
Techology(1)
Telemarketers(1)
Telemarketing(1)
Temp Files(1)
Tennis(1)
Tesla(2)
Texting(12)
Thanksgiving(1)
The Far Side(1)
The Internet Of Things(1)
The Tile(1)
Theaters(1)
Throwback(1)
Thunderbolt(1)
Time Capsule(1)
Time Management(1)
Tip(1)
Tips(34)
Tires(1)
TLDs(1)
Toilets(2)
Toll Booths(1)
Toll Plazas(1)
Toll Tags(4)
Tolls(3)
Tom Cruise(1)
Tonight Show(1)
Tools(3)
Towels(1)
Toys(2)
Traffic(4)
Transgender(1)
Translators(1)
Traps(1)
Travel(4)
Trivia(1)
Trump(3)
Tutorial(1)
TV(31)
TVs(1)
Twinkies(1)
Twitter(7)
Two-Step Security(1)
Uber(7)
Umbrellas(1)
Underwear(1)
Unfair(1)
UPS(3)
Upset Stomach(1)
USB(5)
USPS(3)
Van Halen(1)
Vegans(1)
Video(4)
Video Conferencing(1)
Video Games(3)
Videography(5)
Videos(2)
Virtual PCs(2)
Virus(1)
Viruses(2)
Visual Studio(1)
Vitamins(1)
Vlogging(9)
Voice Recognition(1)
Voice Recorders(1)
Voicemail(2)
Volunteering(1)
Voting(2)
Vudu(1)
Walking Dead(1)
Walmart(1)
War(2)
Washing Machines(1)
Waste(2)
Watches(1)
Water(3)
Waze(1)
Web(17)
Web Design(2)
Website(4)
Websites(1)
WiFi(2)
WiFi Toilets(1)
Wii(1)
Windows(53)
Women(1)
Word(1)
Words(3)
Workplace(1)
Writing(2)
WWE(1)
XBox(1)
Yard Sales(2)
Yellow Pages(1)
Yoda(1)
YouTube(18)
YouTube Live(1)
Zen(1)
Zip Files(1)
Zombies(1)

Recent Activity

30 last Posts
(Originals)