Harlen's Profile User Rating: -----

Reputation: 4 Apprentice
Group:
Members
Active Posts:
40 (0.03 per day)
Joined:
08-February 10
Profile Views:
4,366
Last Active:
User is offline Aug 21 2011 03:02 AM
Currently:
Offline

Previous Fields

Country:
US
OS Preference:
Windows
Favorite Browser:
FireFox
Favorite Processor:
Who Cares
Favorite Gaming Platform:
Playstation
Your Car:
Who Cares
Dream Kudos:
0

Latest Visitors

Icon   Harlen has not set their status

Posts I've Made

  1. In Topic: Need Help with String

    Posted 2 Jul 2011

    It wasn't the single quotes I used for the string, the problem was that I made a typo and did lastIndedOf instead of lastIndexOf. I also didn't fully understand the error message my compiler was giving me. Here's the corrected code.

    class LastNumber {
      public static void main(String args[]) {
        String s1 = "45,39.3,25,5890.7,0.034";
        int i1 = s1.lastIndexOf(',');
        String s2 = s1.substring(i1 + 1);
        System.out.println(s2);
      }
    }
    
    

My Information

Member Title:
New D.I.C Head
Age:
22 years old
Birthday:
February 11, 1991
Gender:
Years Programming:
7
Programming Languages:
HTML 4.01, CSS 2, JavaScript, Java, PHP

Contact Information

E-mail:
Click here to e-mail me

Friends

Harlen hasn't added any friends yet.

Comments

Harlen has no profile comments yet. Why not say hello?