Advertisement
Toxotsist

Task 7 Py3

Mar 14th, 2022
620
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.37 KB | None | 0 0
  1. import numpy as num
  2. import matplotlib.pyplot as plt
  3.  
  4. a = num.random.random((5,2))
  5. a = num.round(a, 0)
  6. b = num.random.random((5,1))
  7. b = num.round(b, 0)
  8. с = num.arange(5,2)
  9. c = num.flip(a, 1)
  10. x = num.concatenate((a,b), 1)
  11. x = num.concatenate((x,c), 1)
  12. x = x.astype(int)
  13.  
  14. fig, ax = plt.subplots()
  15. ax.imshow(x)
  16. fig.set_figwidth(6)
  17. fig.set_figheight(6)
  18. plt.show()
  19.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement