Help java program error code?
-
The program is converting kilograms into pounds. I've compiled it but I keep getting this error Exercise04_05.java:22: error: ' ) ' expected integer.valueOf(kilograms), ((double) kilograms * 2.2000000000000002D), integer.valueOf(pounds), ((double) pounds / 2.2000000000000002D)}; ^ 1 error Can someone help me fix this error and compile it to see if it gives the same error? public static void main(String[] args){ System.out.printf("%10s%10s | %10s%10s\n", new object[] { "kilograms", "pounds", "pounds", "kilograms" }); System.out.println(" "); int kilograms = 1; int pounds = 20; for(int count = 1; count <= 100; count++) { System.out.printf("%10d%10.3f | %10d%10.3f\n", new object[] { integer.valueOf(kilograms), ((double) kilograms * 2.2000000000000002D), integer.valueOf(pounds), ((double) pounds / 2.2000000000000002D)}; kilograms += 2; pounds += 5; } } }
-
Answer:
Shouldn't integer have a capital 'I'?
Yahoo! Answers Visit the source
Other answers
Did you mean to use the Integer class? It is spelled with an initial capital. Java cares about the difference between 'Integer' (what you wanted) and 'integer' (what you have).
Related Q & A:
- What is error code 6 for Yahoo! mail?Best solution by in.answers.yahoo.com
- What does the error code 999 mean?Best solution by Yahoo! Answers
- What is server error code 40402?Best solution by Yahoo! Answers
- Can't delete name off messenger address list, error code 40402,need help pls?Best solution by Yahoo! Answers
- What is error code 504?Best solution by answers.microsoft.com
Just Added Q & A:
- How many active mobile subscribers are there in China?Best solution by Quora
- How to find the right vacation?Best solution by bookit.com
- How To Make Your Own Primer?Best solution by thekrazycouponlady.com
- How do you get the domain & range?Best solution by ChaCha
- How do you open pop up blockers?Best solution by Yahoo! Answers
For every problem there is a solution! Proved by Solucija.
-
Got an issue and looking for advice?
-
Ask Solucija to search every corner of the Web for help.
-
Get workable solutions and helpful tips in a moment.
Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.