There is a command line program called file, here are some examples:
Cocoa Application:
$ file /Applications/Fetch.app/Contents/MacOS/Fetch
/Applications/Fetch.app/Contents/MacOS/Fetch: Mach-O universal binary with 2 architectures
/Applications/Fetch.app/Contents/MacOS/Fetch (for architecture ppc): Mach-O executable ppc
/Applications/Fetch.app/Contents/MacOS/Fetch (for architecture i386): Mach-O executable i386
Carbon Application:
$ file /Applications/Adobe\ Photoshop\ 7/Adobe\ Photoshop\ 7.0/Contents/MacOS/Adobe\ Photoshop\ 7.0
/Applications/Adobe Photoshop 7/Adobe Photoshop 7.0/Contents/MacOS/Adobe Photoshop 7.0: header for PowerPC PEF executable