1. Hi Guest
    We are running a survey about laptop service in India, and we'd love your inputs. Please help us improve the quality of laptop servicing, and if you've had any bad experiences, now is the time to be heard.
    Take the survey

Help needed from Java geek

Discussion in 'QnA (read only)' started by harshagarwal, Oct 20, 2004.

Thread Status:
Not open for further replies.
  1. harshagarwal

    harshagarwal New Member

    Joined:
    Nov 29, 2003
    Messages:
    145
    Likes Received:
    0
    Trophy Points:
    0
    this ones related to JAVA programming.

    how in Java we can compare to strings.

    I am making a small program in which i want to compare two strings.

    please help.
     
  2. Sourabh

    Sourabh Laptoping

    Joined:
    Aug 15, 2004
    Messages:
    2,206
    Likes Received:
    8
    Trophy Points:
    38
    Location:
    Mumbai
    wht are u talking abt??

    is is regarding java or javascript??
    man i know both but i learnt it 2 yrs back by myself so i dunn remember much
    well i feel u want this in java
    lol lemme recollect something

    i guess its tht public static void main shit
    then those curly braces {}
    declaring statements



    hmm but can u temme wht do u mean by comparing 2 strings??
    i knw programs to check the given string is a palindrome or not n kinda stuff in java

    like MALAYALAM n MALAYLAM :lol:
     
  3. OP
    OP
    harshagarwal

    harshagarwal New Member

    Joined:
    Nov 29, 2003
    Messages:
    145
    Likes Received:
    0
    Trophy Points:
    0
    it is regarding Java.
    I am actually making a word game similar to that comes in MID-DAY(a news daily in mumbai).

    so in the game user tries to make english words out of given letters.
    thus I want to compare the word enterd by user to that in the list(which i will prepare).
     
  4. icecoolz

    icecoolz Active Member

    Joined:
    Jul 30, 2004
    Messages:
    1,221
    Likes Received:
    0
    Trophy Points:
    36
    Location:
    Bangalore
    harsh,

    thats not too difficult. If you want to find out if two strings are equal then :

    if(str.equals(str2))
    {
    //Do what you need to do here.
    }
    else
    {

    }

    where str and str2 are two variable of the object String.

    hope this helps.
     
  5. walking-techie

    walking-techie New Member

    Joined:
    Aug 9, 2004
    Messages:
    190
    Likes Received:
    0
    Trophy Points:
    0
    well to late here.. already ansswered ..
     
  6. OP
    OP
    harshagarwal

    harshagarwal New Member

    Joined:
    Nov 29, 2003
    Messages:
    145
    Likes Received:
    0
    Trophy Points:
    0
    hey thanks all of you to solve my problem
     
  7. xenkatesh

    xenkatesh Bewitched!

    Joined:
    Feb 7, 2004
    Messages:
    468
    Likes Received:
    0
    Trophy Points:
    0
    Location:
    chennai
    hey! i dont know java but i can help u check java.sum.com and also javafile.com u can get some helps and tutorials there.
     
Thread Status:
Not open for further replies.

Share This Page