Results 1 to 2 of 2

Thread: helpp

  1. #1
    amzers is offline Member
    Join Date
    Dec 2010
    Posts
    31
    Rep Power
    0

    Default helpp

    I dont really get the reason why i cant run this program,..any help and tips plz?

    --------------------------------------------------------------------------
    public static void main(String[] args) throws IOException {
    BufferedReader input = new BufferedReader(new InputStreamReader(System.in));
    String str1;
    String str2;

    If (str1.length()==str2.length()){
    System.out.println(str1 + " " +str2);}
    Else if
    (str1.length()< str2.length()){
    System.out.println(str1+ " " + str2);
    Else if
    (str1.length() < str2.length()){
    System.out.println(str2+"" + str1);


    }}

  2. #2
    JosAH's Avatar
    JosAH is offline Moderator
    Join Date
    Sep 2008
    Location
    Voorschoten, the Netherlands
    Posts
    13,457
    Blog Entries
    7
    Rep Power
    20

    Default

    'If' and 'Else' don't have a capital first letter: use 'if' and 'else' instead. Oh, and please read a tutorial first before you start guessing.

    kind regards,

    Jos
    cenosillicaphobia: the fear for an empty beer glass

Similar Threads

  1. helpp lol
    By ryzii in forum New To Java
    Replies: 3
    Last Post: 03-26-2009, 02:56 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •