Click here to Skip to main content
14,546,127 members

Welcome to the Lounge

   

For discussing anything related to a software developer's life but is not for programming questions. Got a programming question?

The Lounge is rated Safe For Work. If you're about to post something inappropriate for a shared office environment, then don't post it. No ads, no abuse, and no programming questions. Trolling, (political, climate, religious or whatever) will result in your account being removed.
 
GeneralRe: Humans are ridiculous Pin
honey the codewitch17-Dec-19 18:52
mvahoney the codewitch17-Dec-19 18:52 
GeneralRe: Humans are ridiculous Pin
Super Lloyd17-Dec-19 18:58
MemberSuper Lloyd17-Dec-19 18:58 
GeneralRe: Humans are ridiculous Pin
honey the codewitch17-Dec-19 18:59
mvahoney the codewitch17-Dec-19 18:59 
GeneralRe: Humans are ridiculous Pin
Super Lloyd17-Dec-19 19:03
MemberSuper Lloyd17-Dec-19 19:03 
GeneralRe: Humans are ridiculous Pin
honey the codewitch17-Dec-19 19:07
mvahoney the codewitch17-Dec-19 19:07 
GeneralRe: Humans are ridiculous Pin
Super Lloyd17-Dec-19 19:20
MemberSuper Lloyd17-Dec-19 19:20 
GeneralRe: Humans are ridiculous Pin
Nelek18-Dec-19 0:29
protectorNelek18-Dec-19 0:29 
GeneralRe: Humans are ridiculous Pin
Super Lloyd17-Dec-19 19:01
MemberSuper Lloyd17-Dec-19 19:01 
2nd option, perhaps to your liking, but really slower, using more memory, less readable
but it does avoid the local count variable
var list = new HashSet<object>() { };
var result = new StringBuilder();

foreach (var item in list)
{
    if (result.Length > 0)
        result.Remove(result.Length - 3, 3);
    result.Append(item);
    result.Append(",or ");
}

return result.ToString();
A new .NET Serializer
All in one Menu-Ribbon Bar
Taking over the world since 1371!

GeneralRe: Humans are ridiculous Pin
honey the codewitch17-Dec-19 19:02
mvahoney the codewitch17-Dec-19 19:02 
GeneralENGLISH is ridiculous Pin
Daniel Pfeffer17-Dec-19 19:29
professionalDaniel Pfeffer17-Dec-19 19:29 
GeneralRe: ENGLISH is ridiculous Pin
honey the codewitch17-Dec-19 19:31
mvahoney the codewitch17-Dec-19 19:31 
GeneralRe: ENGLISH is ridiculous Pin
Super Lloyd17-Dec-19 20:45
MemberSuper Lloyd17-Dec-19 20:45 
GeneralRe: ENGLISH is ridiculous Pin
PIEBALDconsult18-Dec-19 6:23
professionalPIEBALDconsult18-Dec-19 6:23 
GeneralRe: ENGLISH is ridiculous Pin
TheGreatAndPowerfulOz18-Dec-19 6:33
MemberTheGreatAndPowerfulOz18-Dec-19 6:33 
GeneralRe: ENGLISH is ridiculous Pin
honey the codewitch17-Dec-19 19:33
mvahoney the codewitch17-Dec-19 19:33 
GeneralRe: Humans are ridiculous Pin
Richard Deeming18-Dec-19 0:06
mveRichard Deeming18-Dec-19 0:06 
GeneralRe: Humans are ridiculous Pin
StarNamer_18-Dec-19 2:44
professionalStarNamer_18-Dec-19 2:44 
GeneralRe: Humans are ridiculous Pin
honey the codewitch18-Dec-19 2:45
mvahoney the codewitch18-Dec-19 2:45 
GeneralRe: Humans are ridiculous Pin
StarNamer_18-Dec-19 3:47
professionalStarNamer_18-Dec-19 3:47 
GeneralRe: Humans are ridiculous Pin
honey the codewitch18-Dec-19 3:49
mvahoney the codewitch18-Dec-19 3:49 
GeneralMini CCCs 156 Pin
Tim Deveaux17-Dec-19 16:37
MemberTim Deveaux17-Dec-19 16:37 
GeneralRe: Mini CCCs 156 Pin
OriginalGriff17-Dec-19 20:51
mveOriginalGriff17-Dec-19 20:51 
GeneralRe: Mini CCCs 156 Pin
Tim Deveaux18-Dec-19 1:17
MemberTim Deveaux18-Dec-19 1:17 
Generalimages of a wondrous world PinPopular
BillWoodruff17-Dec-19 8:21
mveBillWoodruff17-Dec-19 8:21 
GeneralRe: images of a wondrous world Pin
Rick York17-Dec-19 9:27
mveRick York17-Dec-19 9:27 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.