Search...
FAQs
Subscribe
Pie
FAQs
Recent topics
Flagged topics
Hot topics
Best topics
Search...
Search within OCPJP
Search Coderanch
Advance search
Google search
Register / Login
Post Reply
Bookmark Topic
Watch Topic
New Topic
programming forums
Java
Mobile
Certification
Databases
Caching
Books
Engineering
Micro Controllers
OS
Languages
Paradigms
IDEs
Build Tools
Frameworks
Application Servers
Open Source
This Site
Careers
Other
Pie Elite
all forums
this forum made possible by our volunteer staff, including ...
Marshals:
Campbell Ritchie
Jeanne Boyarsky
Ron McLeod
Paul Clapham
Liutauras Vilda
Sheriffs:
paul wheaton
Rob Spoor
Devaka Cooray
Saloon Keepers:
Stephan van Hulst
Tim Holloway
Carey Brown
Frits Walraven
Tim Moores
Bartenders:
Mikalai Zaikin
Forum:
Programmer Certification (OCPJP)
java.util.Locale will accept any String...
T Vergilio
Ranch Hand
Posts: 241
5
posted 12 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
and will compile and run! Watch out for this one on the exam:
import java.util.Locale; class TestLocale { public static void main(String[] args) { Locale lc=new Locale("heaven"); System.out.println(lc.getDisplayName()); } }
The output is:
heaven
Process completed.
OCA Java 6, OCP Java 6, OCP Java 8
Rajkamal Pillai
Ranch Hand
Posts: 479
1
I like...
posted 12 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
Is that an observation or a question?
T Vergilio
Ranch Hand
Posts: 241
5
posted 12 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
It was an observation. I don't really know why, but just realised that it happens, so it's something to watch out for.
OCA Java 6, OCP Java 6, OCP Java 8
With a little knowledge, a
cast iron skillet
is non-stick and lasts a lifetime.
reply
reply
Bookmark Topic
Watch Topic
New Topic
Boost this thread!
Similar Threads
is it possible to change jvm locale by using command line parameters ?
Getting locale/language in struts beans
Struts2 Internationalization
Calendar with Locale
ResourceBundle not using Locale
More...