Click here to Skip to main content
15,915,093 members
Home / Discussions / C#
   

C#

 
QuestionCombine Array Values in C# Pin
Member 130810652-Dec-20 3:51
Member 130810652-Dec-20 3:51 
I have an array of string which is 

    string[] myarr = new[] { "a", "b", "c" };

Can you please help me how to get this result?

    a
    ab
    abc

I tried this one but I just don't know how to get the value from the array and add it on my list 

    string[] myarray = new string[] { "a", "b", "c" };
                List<string> resultarray = new List<string>();

                int i, j;
                for (i = 0; i <= myarray.Length; i++)
                {
                    for (j = i; j <= i; j++)
                    {

                        


                    }
                }

AnswerRe: Combine Array Values in C# Pin
Richard MacCutchan2-Dec-20 4:02
mveRichard MacCutchan2-Dec-20 4:02 
AnswerRe: Combine Array Values in C# Pin
Richard Deeming2-Dec-20 4:08
mveRichard Deeming2-Dec-20 4:08 
AnswerRe: Combine Array Values in C# Pin
OriginalGriff2-Dec-20 4:31
mveOriginalGriff2-Dec-20 4:31 
AnswerRe: Combine Array Values in C# Pin
Gerry Schmitz2-Dec-20 5:33
mveGerry Schmitz2-Dec-20 5:33 
QuestionUnity connection with a smartwatch and getting heart rate data Pin
SkyVenus30-Nov-20 23:30
SkyVenus30-Nov-20 23:30 
AnswerRe: Unity connection with a smartwatch and getting heart rate data Pin
Sandeep Mewara1-Dec-20 0:06
mveSandeep Mewara1-Dec-20 0:06 
GeneralRe: Unity connection with a smartwatch and getting heart rate data Pin
SkyVenus1-Dec-20 3:11
SkyVenus1-Dec-20 3:11 
AnswerRe: Unity connection with a smartwatch and getting heart rate data Pin
Gerry Schmitz1-Dec-20 5:34
mveGerry Schmitz1-Dec-20 5:34 
GeneralRe: Unity connection with a smartwatch and getting heart rate data Pin
OriginalGriff1-Dec-20 9:30
mveOriginalGriff1-Dec-20 9:30 
GeneralRe: Unity connection with a smartwatch and getting heart rate data Pin
Gerry Schmitz1-Dec-20 18:23
mveGerry Schmitz1-Dec-20 18:23 
QuestionDifferences Pin
michaelbarb30-Nov-20 5:53
michaelbarb30-Nov-20 5:53 
AnswerRe: Differences Pin
OriginalGriff30-Nov-20 6:20
mveOriginalGriff30-Nov-20 6:20 
GeneralRe: Differences Pin
michaelbarb30-Nov-20 6:39
michaelbarb30-Nov-20 6:39 
QuestionIs my program idea possible? Pin
Dioxazine27-Nov-20 20:09
Dioxazine27-Nov-20 20:09 
AnswerRe: Is my program idea possible? Pin
OriginalGriff27-Nov-20 20:20
mveOriginalGriff27-Nov-20 20:20 
GeneralRe: Is my program idea possible? Pin
Dioxazine28-Nov-20 5:54
Dioxazine28-Nov-20 5:54 
GeneralRe: Is my program idea possible? Pin
OriginalGriff28-Nov-20 6:17
mveOriginalGriff28-Nov-20 6:17 
GeneralRe: Is my program idea possible? Pin
Dioxazine28-Nov-20 8:09
Dioxazine28-Nov-20 8:09 
GeneralRe: Is my program idea possible? Pin
OriginalGriff28-Nov-20 8:22
mveOriginalGriff28-Nov-20 8:22 
GeneralRe: Is my program idea possible? Pin
Liktor Janos11-Dec-20 7:42
Liktor Janos11-Dec-20 7:42 
GeneralRe: Is my program idea possible? Pin
Gerry Schmitz28-Nov-20 7:51
mveGerry Schmitz28-Nov-20 7:51 
QuestionError in SQL Light Compact 4 Pin
Alex Dunlop23-Nov-20 3:47
Alex Dunlop23-Nov-20 3:47 
AnswerRe: Error in SQL Light Compact 4 Pin
Victor Nijegorodov23-Nov-20 3:56
Victor Nijegorodov23-Nov-20 3:56 
GeneralRe: Error in SQL Light Compact 4 Pin
Alex Dunlop23-Nov-20 4:04
Alex Dunlop23-Nov-20 4:04 

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.