Untitled
unknown
plain_text
8 months ago
306 B
1
Indexable
Never
#include <iostream> #include <fstream> using namespace std; void y(ofstream &file, int n) { int i = 1; while (i <= n) { file << i << " "; cout << i << " "; i++; } } int main(){ int n; cin >> n; ofstream file("y(x).txt"); y(file, n); }
Leave a Comment