aspose file tools*
The moose likes Beginning Java and the fly likes Which different between these two methods please? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Which different between these two methods please?" Watch "Which different between these two methods please?" New topic
Author

Which different between these two methods please?

André Asantos
Ranch Hand

Joined: Nov 23, 2009
Posts: 234
Which different between these two methods please?

Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14687
    
  16

somarValores adds two numbers, like 1+2=3. soma performs a binary AND, like 0110 & 1100 = 0100 (see this).


[My Blog]
All roads lead to JavaRanch
Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19696
    
  20

These are definitely not the same. For example, 1 + 1 == 2 while 1 & 1 == 1.


SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6
How To Ask Questions How To Answer Questions
marc weber
Sheriff

Joined: Aug 31, 2004
Posts: 11343

...not to mention the return types.


"We're kind of on the level of crossword puzzle writers... And no one ever goes to them and gives them an award." ~Joe Strummer
sscce.org
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: Which different between these two methods please?