#include <iostream> #include <fstream> #include <cstdlib> using namespace std; int main(int argc, char *argv[]) { char ch; ifstream in("test.txt", ios::in | ios::binary); if(!in) { cout << "Cannot open file.\n"; return 1; } in.seekg(1, ios::beg); while(in.get(ch)) cout << ch; return 0; }
0 123.23 This is a text.