ByteReader - DataInputStream in2 = new DataInputStream(new

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
package lab08; p import; import; import; import; import; import; i public class ByteReader { p public static void main(String[] args) throws FileNotFoundException, IOException { FileInputStream in = new FileInputStream("C:\\Users\\Aldin's Laptop W7\\Desktop\\Coms 227 Files\\lab08.bin");
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: DataInputStream in2 = new DataInputStream(new FileInputStream("C:\\Users\\Aldin's Laptop W7\\Desktop\\Coms 227 Files\\out2.bin")); F // int datum =; // while (datum != -1) { // System.out.println(datum); // datum =; // } double pi =in2.readDouble(); int five = in2.readInt(); boolean a = in2.readBoolean(); in2.close(); in.close(); i System.out.println(pi + "\n " + five + "\n" + a); } }...
View Full Document

This note was uploaded on 09/20/2011 for the course COM SCI 227 taught by Professor Staff during the Spring '11 term at Iowa State.

Ask a homework question - tutors are online