标签:
#include <fstream> #include <iostream> int main(void) { char url[1000] = {0}; int buff_len = 1000; std::ifstream read("./urls"); if (!read) { std::cout << "open file err!" << std::endl; return -1; } while( !(read.peek() == EOF) ) { read.getline(url, buff_len); std::cout << url << std::endl; } read.close(); }
标签:
原文地址:http://www.cnblogs.com/i80386/p/4934915.html