I'm looking to xor two integers together in Fortran, is there a function in FTN95 to do this?
Bitwise xor
IEOR (i,j)
There's a whole slew of such functions introduced in Fortran 90 and referenced in FTN95.chm. In addition, FTN77 had a few functions for setting and reading individual bits - see the FTN77 Library Reference Manual in the support section of the website.
Eddie
Thanks both, I did check the docs by searching for XOR couldn't find it.
Ryan,
I couldn't find it either, as FTN95.CHM doesn't have the sort of language guide that you used to get with printed documentation. I found a whole lot of information on bit operations here:
https://rosettacode.org/wiki/Bitwise_operations#Fortran
which gives the Fortran 90 routines as well as IEOR for all the related operations.
Eddie