how to input a string in an array

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • blass
    New Member
    • May 2007
    • 1

    how to input a string in an array

    help please

    now
    yes now
  • r035198x
    MVP
    • Sep 2006
    • 13225

    #2
    Originally posted by blass
    help please

    now
    yes now
    How do you think it should be done ?
    Have you read any tutorials?

    Comment

    • JosAH
      Recognized Expert MVP
      • Mar 2007
      • 11453

      #3
      Originally posted by blass
      help please

      now
      yes now
      That sounds rather demanding doesn't it? You should start with supplying a bit
      more information, because your terse message just tells me this:[code=java]
      String aString= "aString";
      String[] anArray;[/code]
      Now what?

      kind regards,

      Jos

      Comment

      • rsrinivasan
        New Member
        • Mar 2007
        • 221

        #4
        Originally posted by blass
        help please

        now
        yes now

        hi,

        Normal String input:

        String str = "Hi";

        Array String Input:

        String str[] = new String[10]; // Array Declaration
        str[0] = "string0";
        str[1] = "string1";
        .
        .
        .
        .
        str[9] = "string9";

        Thanks,

        Comment

        • emekadavid
          New Member
          • Mar 2007
          • 46

          #5
          that's how it should be done. now for a cup of unearned coffee.

          Comment

          Working...