Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<iostream>
- using namespace std;
- int main()
- {
- unsigned short n;
- cout << "n = ";
- cin >> n;
- float* mas = new float[n];
- float* mas2 = new float[n-1];
- int p;
- for (int i = 0; i < n; i++)
- cin >> mas[i];
- for(int i=0 ; i < n ; i++)
- cout << mas[i] << " " ;
- cout << endl;
- int pos;
- cin >> pos;
- for(int i=pos; i < n ;i++){
- mas2[p]=mas[i];
- p++;
- }
- for(int i = 0 ; i < n-1 ; i++)
- cout << mas2[i] << " ";
- delete []mas;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement