Dzisiejsze laby. Reszta kiedy indziej

This commit is contained in:
2022-11-30 16:50:53 +01:00
parent 3f67343476
commit 48083a47de
2 changed files with 36 additions and 0 deletions

View File

@@ -0,0 +1,19 @@
#include <iostream>
#include <fstream>
#include <string>
using namespace std;
int czytaj(char *nazwa){
ifstream plik(nazwa);
string linia;
while (getline(plik, linia)) {
std::cout << linia << std::endl;
}
plik.close();
return 0;
}
int main (int argc, char *argv[])
{
czytaj(argv[1]);
return 0;
}