Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main()
- {
- cout << "3.28\n" << endl;
- int tablica[4][5];
- int x=1;
- for(int i=0;i<4;i++) //wpisanie liczb
- {
- for(int j=0;j<5;j++)
- {
- tablica[i][j]=x;
- x++;
- }
- }
- for(int i=0;i<4;i++)
- {
- for(int j=0;j<5;j++)
- {
- cout<<tablica[i][j]<<"\t";
- }
- cout<<endl;
- }
- int wiersz;
- cout<<"Podaj wiersz: " ;
- cin>>wiersz;
- for(int i=wiersz;i<4;i++)
- {
- for(int j=0;j<5;j++)
- {
- tablica[i][j]=tablica[i+1][j];
- }
- cout<<endl;
- }
- for(int j=0;j<5;j++)
- {
- tablica[3][j]=0;
- }
- cout<<endl;
- for(int i=0;i<4;i++)
- {
- for(int j=0;j<5;j++)
- {
- cout<<tablica[i][j]<<"\t";
- }
- cout<<endl;
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement