Advertisement
Guest User

Untitled

a guest
Nov 27th, 2014
157
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.42 KB | None | 0 0
  1. void nuskaitymas( int Z[][30], int &n, int &m)
  2. {
  3.  
  4. n = 0;
  5. m = 0;
  6.  
  7. ifstream fd("duom.txt");
  8.  
  9. while (!fd.eof())
  10. {
  11.  
  12.  
  13. fd >> Z[n][m];
  14. n++;
  15. m++;
  16.  
  17. }
  18.  
  19. fd.close();
  20. }
  21.  
  22. void isvedimas(int Z[][30], int n, int m)
  23. {
  24.  
  25. n=0;
  26. m=0;
  27.  
  28. ofstream fr("rez.txt");
  29.  
  30. for (int i=0; i<n; i++)
  31. {
  32. for (int j=0; j<m; j++)
  33. {
  34.  
  35. fr << Z[n][m] << endl;
  36.  
  37.  
  38. }
  39.  
  40.  
  41.  
  42. }
  43.  
  44. fr.close();
  45. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement