The longest queue I've ever stood in was outside the passport office in Lahore, about four years ago. I needed to renew my passport urgently because I'd been offered a place on a summer course in Malaysia, and the online appointment system was fully booked for weeks.
Someone told me that if I arrived early, I could join the walk-in queue, so I got there at five in the morning. To my horror, there were already about two hundred people in front of me, some of whom had brought folding chairs and flasks of tea. The doors didn't open until eight, and after that the queue moved painfully slowly, because each person had to have their fingerprints and photo taken. I finally got to the counter at around two in the afternoon, which means I'd been waiting for nine hours.
My feelings changed over the day. For the first couple of hours I was irritated and kept checking how many people were ahead of me, which only made it worse. Around midday, the heat was unbearable and I was seriously thinking of giving up. But something unexpected happened: I started chatting to the people around me. There was an elderly man going to see his grandson in Canada for the first time, and a young woman going to study nursing in Ireland. We shared snacks and took turns holding each other's places. By the time I reached the counter, it felt less like a waste of time and more like a strange little community. I still wouldn't choose to do it again, though.