Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include "stdafx.h"
- #include <iostream>
- #include <fstream>
- #include <stdio.h>
- #include <conio.h>
- #include <time.h>
- using namespace std;
- int main()
- {
- setlocale(LC_ALL, "Russian");
- ofstream fout;
- int n = 20; int i;
- int massive[20];
- srand(time(0));
- fout.open("E:\text1.txt");
- for (i = 1; i < n; i++)
- {
- massive[i] = -10 + rand() % 21;
- }
- fout << n << "\n";
- fout.close();
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement