• 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

Strictfp

 
Ranch Hand
Posts: 55
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What is strictfp ? In what way is it related to float and double expressions ?
 
Cowgirl and Author
Posts: 1589
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Howdy -- strictfp is a modifier that can be applied to a class or a method, and as far as the exam is concerned:
* If marking a method, it forces the method to be strictfp-compliant, which means it adheres to the IEEE 754 standard for floating point numbers, as opposed to using whatever precision the underlying platform can support (which could be *greater* but is always at least guaranteed by the Java spec to be IEEE 754 compliant).
* If marking a class, it means that all methods in that class are strictfp.
And then, of course, you also have to know the details of the IEEE 754 specification. But it is not that bad, really!
OK, just kidding about the spec -- you do NOT have to know anything more than what the strictfp modifier is for, and where it can be used (e.g. on a class or method, but not a variable, etc.)
Cheers,
Kathy
 
Salim Mohamed
Ranch Hand
Posts: 55
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thank you ...
 
Ranch Hand
Posts: 2120
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Salim, compile constant expressions (JLS 15.28) are also implicitly strictfp.
[ November 01, 2002: Message edited by: Jose Botella ]
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic