Advertisement
Guest User

Untitled

a guest
May 30th, 2015
246
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.01 KB | None | 0 0
  1. #include <iostream>
  2. #include <fstream>
  3. #include <string>
  4.  
  5. using namespace std;
  6. int main()
  7. {
  8. int L,i,j,y;
  9. cin >> L;
  10. int H;
  11. cin >> H;
  12. char a[30][900],N[200];
  13. cin>>N;
  14. for(i=1;i<=H;i++)
  15. for(j=1;j<=L*27+1;j++)
  16. cin>>noskipws>>a[i][j];
  17. for(i=1;i<=H;i++)
  18. {
  19. for(y=1;y<=200;y++)
  20. {
  21. if(int(N[y-1])>=65&&int(N[y-1])<=90)
  22. for(j=(int(N[y-1])-65)*L+2;j<=(int(N[y-1]-64))*L+1;j++)
  23. cout<<a[i][j];
  24. else
  25. if(int(N[y-1])>=97&&int(N[y-1])<=122)
  26. for(j=(int(N[y-1])-97)*L+2;j<=(int(N[y-1]-96))*L+1;j++)
  27. cout<<a[i][j];
  28. else
  29. for(j=26*L+2;j<=27*L+1;j++)
  30. cout<<a[i][j];
  31. if(int(N[y])==0)
  32. y=201;
  33. }
  34. cout<<endl;
  35. }
  36. return 0;
  37. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement