source:
fact/tools/pyscripts/sandbox/dneise/fact_compress/c++/test2.cpp@
17689
Last change on this file since 17689 was 14268, checked in by , 12 years ago | |
---|---|
File size: 317 bytes |
Line | |
---|---|
1 | #include <iostream> |
2 | #include <fstream> |
3 | #include <stdio.h> |
4 | |
5 | using namespace std; |
6 | int main() |
7 | { |
8 | ifstream in ("test.bin", ios::binary); |
9 | |
10 | short *b = new short[10]; |
11 | |
12 | in.read((char*)b, 20); |
13 | |
14 | for (int i=0; i<10; i++) |
15 | { |
16 | printf("%X ", (unsigned short)b[i]); |
17 | } |
18 | cout << endl; |
19 | |
20 | in.close(); |
21 | return 0; |
22 | } |
Note:
See TracBrowser
for help on using the repository browser.